Skip to content

Commit 80ce6ff

Browse files
greg-1-andersonweitzman
authored andcommitted
Combine phpunit configuration for unit and functional tests into a single file, and move it back to its historic location. (#3798)
1 parent 7d67a93 commit 80ce6ff

File tree

4 files changed

+11
-34
lines changed

4 files changed

+11
-34
lines changed

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Drush is built by people like you! Please [join us](https://github.com/drush-ops
44
* Contributions are submitted, reviewed, and accepted using GitHub pull requests.
55
* The latest changes are in the `master` branch. PR's should initially target this branch.
66
* Try to make clean commits that are easily readable (including descriptive commit messages!)
7-
* Test before you push. Get familiar with Unish, our test suite. See the test-specific [README.md](tests/README.md). Optionally run tests in the provided Docker containers.
7+
* See the test-specific [README.md](tests/README.md) for instructions on running the test suite. Test before you push. Get familiar with Unish, our test suite. Optionally run tests in the provided Docker containers.
88
* We maintain branches named 9.x, 8.x, etc. These are release branches. From these branches, we make new tags for patch and minor versions.
99

1010
## Development Environment

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,8 @@
107107
"scenario": "scenarios/install",
108108
"sut": "./drush --uri=dev",
109109
"sut:si": "./drush site:install testing --uri=dev --sites-subdir=dev --db-url=${UNISH_DB_URL:-mysql://root:password@mariadb}/unish_dev -v",
110-
"unit": "phpunit --colors=always --configuration tests/unit",
111-
"functional": "phpunit --colors=always --configuration tests/functional",
110+
"unit": "phpunit --colors=always --configuration tests --testsuite unit",
111+
"functional": "phpunit --colors=always --configuration tests --testsuite functional",
112112
"post-update-cmd": [
113113
"create-scenario phpunit4 --autoload-dir internal-copy 'phpunit/phpunit:^4.8.36'"
114114
]

tests/functional/phpunit.xml.dist renamed to tests/phpunit.xml.dist

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,23 @@
11
<!--
2-
This is the phpunit configuration file for the functional tests.
3-
For the unit tests configuration, see the phpunit.xml.dist file
4-
at the root of the project.
5-
62
Copy and rename this file to phpunit.xml to customize.
73
84
The variables shown below must usually be defined in order to run the
95
functional tests. They may be set by customizing this file, or they may
106
be defined as environment variables. Alternately, you may run the
117
tests without defining these variables if you use the default values.
128
-->
13-
<phpunit backupGlobals="false"
9+
<phpunit
10+
bootstrap="../vendor/autoload.php"
11+
backupGlobals="false"
1412
backupStaticAttributes="false"
1513
syntaxCheck="false"
1614
colors="true">
1715
<testsuites>
18-
<testsuite name="Drush Test Suite">
19-
<directory>.</directory>
16+
<testsuite name="unit">
17+
<directory suffix="Test.php">unit</directory>
18+
</testsuite>
19+
<testsuite name="functional">
20+
<directory>functional</directory>
2021
</testsuite>
2122
</testsuites>
2223

tests/unit/phpunit.xml.dist

Lines changed: 0 additions & 24 deletions
This file was deleted.

0 commit comments

Comments
 (0)