Skip to content

Commit 5ef91ae

Browse files
committed
Remove davereid from namespace.
1 parent cefe481 commit 5ef91ae

File tree

10 files changed

+21
-16
lines changed

10 files changed

+21
-16
lines changed

composer.json

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,12 @@
3232
},
3333
"autoload": {
3434
"psr-4": {
35-
"Davereid\\DrupalEnvironment\\": "src/"
35+
"DrupalEnvironment\\": "src/"
3636
}
3737
},
3838
"autoload-dev": {
3939
"psr-4": {
40-
"Davereid\\DrupalEnvironment\\Tests\\": "tests/src/"
40+
"DrupalEnvironment\\Tests\\": "tests/src/"
4141
}
4242
},
4343
"extra": {
@@ -46,8 +46,11 @@
4646
}
4747
},
4848
"scripts": {
49+
"lint": [
50+
"@phpcs",
51+
"@phpstan"
52+
],
4953
"test": [
50-
"@phpstan",
5154
"@phpunit"
5255
],
5356
"phpcs": "vendor/bin/phpcs --standard=PSR1,PSR2 src tests",

src/Acquia.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Davereid\DrupalEnvironment;
3+
namespace DrupalEnvironment;
44

55
/**
66
* The Acquia environment specifics.

src/CircleCi.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Davereid\DrupalEnvironment;
3+
namespace DrupalEnvironment;
44

55
/**
66
* The CircleCI environment specifics.

src/DefaultEnvironment.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Davereid\DrupalEnvironment;
3+
namespace DrupalEnvironment;
44

55
/**
66
* The standard environment.

src/Environment.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Davereid\DrupalEnvironment;
3+
namespace DrupalEnvironment;
44

55
/**
66
* Helpers for working with the Drupal environment.

src/GitHubWorkflow.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Davereid\DrupalEnvironment;
3+
namespace DrupalEnvironment;
44

55
/**
66
* The GitHub Workflow environment specifics.

src/GitLabCi.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Davereid\DrupalEnvironment;
3+
namespace DrupalEnvironment;
44

55
/**
66
* The GitlabCi environment specifics.

src/Pantheon.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Davereid\DrupalEnvironment;
3+
namespace DrupalEnvironment;
44

55
/**
66
* The Pantheon environment specifics.

src/Tugboat.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Davereid\DrupalEnvironment;
3+
namespace DrupalEnvironment;
44

55
/**
66
* The Tugboat environment specifics.

tests/src/EnvironmentTest.php

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

3-
namespace Davereid\DrupalEnvironment\Tests;
3+
namespace DrupalEnvironment\Tests;
44

5-
use Davereid\DrupalEnvironment\Environment;
5+
use DrupalEnvironment\Environment;
66
use PHPUnit\Framework\TestCase;
77

88
/**
@@ -37,17 +37,19 @@ public function testEnvironment(array $variables, array $method_tests): void
3737
'GITLAB_CI' => null,
3838
'GITHUB_WORKFLOW' => null,
3939
];
40-
$originals = [];
41-
$this->setEnvironmentVariables($variables, $originals);
40+
$this->setEnvironmentVariables($variables);
4241
foreach ($method_tests as $name => $expected) {
4342
$this->assertSame($expected, Environment::$name(), "Asserting Environment::$name");
4443
}
45-
$this->setEnvironmentVariables($originals);
4644
}
4745

4846
/**
47+
* Set environment variables manually for testing.
48+
*
4949
* @param array $variables
50+
* The variable values to set keyed by name.
5051
* @param array|null $originals
52+
* If provided will be populated with the original variable values keyed by name.
5153
*/
5254
protected function setEnvironmentVariables(array $variables, ?array &$originals = null): void
5355
{

0 commit comments

Comments
 (0)