@@ 358-368 (lines=11) @@ | ||
355 | $this->assertSame(3, $enumSet->count()); |
|
356 | } |
|
357 | ||
358 | public function testSetBinaryBitsetLe() |
|
359 | { |
|
360 | $enumSet = new EnumSet('MabeEnumTest\TestAsset\Enum65'); |
|
361 | $enumSet->setBinaryBitsetLe("\x01\x00\x00\x00\x00\x00\x00\x80\x01"); |
|
362 | ||
363 | $this->assertTrue($enumSet->contains(Enum65::ONE)); |
|
364 | $this->assertFalse($enumSet->contains(Enum65::TWO)); |
|
365 | $this->assertTrue($enumSet->contains(Enum65::SIXTYFIVE)); |
|
366 | $this->assertTrue($enumSet->contains(Enum65::SIXTYFOUR)); |
|
367 | $this->assertTrue($enumSet->count() == 3); |
|
368 | } |
|
369 | ||
370 | public function testSetBinaryBitsetBe() |
|
371 | { |
|
@@ 370-380 (lines=11) @@ | ||
367 | $this->assertTrue($enumSet->count() == 3); |
|
368 | } |
|
369 | ||
370 | public function testSetBinaryBitsetBe() |
|
371 | { |
|
372 | $enumSet = new EnumSet('MabeEnumTest\TestAsset\Enum65'); |
|
373 | $enumSet->setBinaryBitsetBe("\x01\x80\x00\x00\x00\x00\x00\x00\x01"); |
|
374 | ||
375 | $this->assertTrue($enumSet->contains(Enum65::ONE)); |
|
376 | $this->assertFalse($enumSet->contains(Enum65::TWO)); |
|
377 | $this->assertTrue($enumSet->contains(Enum65::SIXTYFIVE)); |
|
378 | $this->assertTrue($enumSet->contains(Enum65::SIXTYFOUR)); |
|
379 | $this->assertTrue($enumSet->count() == 3); |
|
380 | } |
|
381 | ||
382 | /** |
|
383 | * @deprecated |
|
@@ 385-395 (lines=11) @@ | ||
382 | /** |
|
383 | * @deprecated |
|
384 | */ |
|
385 | public function testSetBitset() |
|
386 | { |
|
387 | $enumSet = new EnumSet('MabeEnumTest\TestAsset\Enum65'); |
|
388 | $enumSet->setBitset("\x01\x80\x00\x00\x00\x00\x00\x00\x01"); |
|
389 | ||
390 | $this->assertTrue($enumSet->contains(Enum65::ONE)); |
|
391 | $this->assertFalse($enumSet->contains(Enum65::TWO)); |
|
392 | $this->assertTrue($enumSet->contains(Enum65::SIXTYFIVE)); |
|
393 | $this->assertTrue($enumSet->contains(Enum65::SIXTYFOUR)); |
|
394 | $this->assertTrue($enumSet->count() == 3); |
|
395 | } |
|
396 | ||
397 | public function testSetBinaryBitsetLeShort() |
|
398 | { |