Skip to content

Commit f7e8afc

Browse files
committed
fixed namespace
1 parent 7d7e011 commit f7e8afc

File tree

5 files changed

+18
-16
lines changed

5 files changed

+18
-16
lines changed

composer.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,19 +11,19 @@
1111
],
1212
"require-dev": {
1313
"php": ">=7.1",
14-
"phpunit/phpunit": "~6.3",
14+
"phpunit/phpunit": "~6.0",
1515
"phpunit/php-code-coverage": "~5.2",
1616
"squizlabs/php_codesniffer": "2.*"
1717
},
1818
"autoload": {
1919
"psr-4": {
20-
"SdoBitmask\\": "src/"
20+
"Sdo\\Bitmask\\": "src/"
2121
}
2222
},
2323
"autoload-dev": {
2424
"psr-4": {
25-
"SdoBitmask\\": "src/",
26-
"SdoBitmask\\Tests\\": "test/unit"
25+
"Sdo\\Bitmask\\": "src/",
26+
"Sdo\\Bitmask\\Tests\\": "test/unit"
2727
}
2828
}
2929
}

src/AbstractBitmask.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace SdoBitmask;
3+
namespace Sdo\Bitmask;
44

55
/**
66
* Simple bitmask class to set bitmasks
@@ -90,14 +90,15 @@ public function setFlag(int $flag, bool $set = true): self
9090
* @param int $flag Bitmask flag
9191
*
9292
* @return self
93+
* @throws \Exception
9394
*/
9495
public function unsetFlag(int $flag): self
9596
{
9697
return $this->setFlag($flag, false);
9798
}
9899

99100
/**
100-
* Checks whether a flag is power of two or not
101+
* Checks whether a flag is a power of two or not
101102
*
102103
* @param int $flag Flag of bitmask
103104
*

test/unit/RsdBitmaskTest.php

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<?php
22

3-
namespace SdoBitmask\Tests;
3+
namespace Sdo\Bitmask\Tests;
44

5-
use SdoBitmask\Tests\Stubs\FirstBitmask;
5+
use Sdo\Bitmask\Tests\Stubs\FirstBitmask;
66

77
/**
88
* SdoBitmask tests
@@ -20,7 +20,7 @@ class SdoBitmaskTest extends \PHPUnit\Framework\TestCase
2020
*
2121
* @return void
2222
*/
23-
public function testInit()
23+
public function testInit(): void
2424
{
2525
$firstBitmask = new FirstBitmask(0);
2626

@@ -33,8 +33,9 @@ public function testInit()
3333
* Checks whether given flags are set or not
3434
*
3535
* @return void
36+
* @throws \Exception
3637
*/
37-
public function testSetFlag()
38+
public function testSetFlag(): void
3839
{
3940
$firstBitmask = new FirstBitmask(0);
4041

@@ -63,7 +64,7 @@ public function testSetFlag()
6364
*
6465
* @return void
6566
*/
66-
public function testSetIllegalFlag()
67+
public function testSetIllegalFlag(): void
6768
{
6869
$firstBitmask = new FirstBitmask(0);
6970

@@ -80,7 +81,7 @@ public function testSetIllegalFlag()
8081
*
8182
* @return void
8283
*/
83-
public function testSetNegativeBitmask()
84+
public function testSetNegativeBitmask(): void
8485
{
8586
try {
8687
new FirstBitmask(-2);

test/unit/Stubs/FirstBitmask.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<?php
22

3-
namespace SdoBitmask\Tests\Stubs;
3+
namespace Sdo\Bitmask\Tests\Stubs;
44

5-
use SdoBitmask\AbstractBitmask;
5+
use Sdo\Bitmask\AbstractBitmask;
66

77
/**
88
* Simple class with constant bitmask flags

test/unit/Stubs/SecondBitmask.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<?php
22

3-
namespace SdoBitmask\Tests\Stubs;
3+
namespace Sdo\Bitmask\Tests\Stubs;
44

5-
use SdoBitmask\AbstractBitmask;
5+
use Sdo\Bitmask\AbstractBitmask;
66

77
/**
88
* Simple class with constant bitmask flags

0 commit comments

Comments
 (0)