Skip to content

Commit dc26479

Browse files
committed
Install testing dependencies with composer
1 parent 5b2c54c commit dc26479

File tree

3 files changed

+33
-4
lines changed

3 files changed

+33
-4
lines changed

composer.json

+23-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,24 @@
11
{
22
"name": "barberry/barberry",
3-
"version": "1.0.0",
43
"license": "MIT",
4+
"repositories": [
5+
{
6+
"type": "package",
7+
"package": {
8+
"name": "hamcrest/hamcrest",
9+
"version": "1.1.0",
10+
"dist": {
11+
"type": "zip",
12+
"url": "https://hamcrest.googlecode.com/files/hamcrest-php-1.1.0.zip"
13+
},
14+
"include-path": ["Hamcrest-1.1.0/"],
15+
"autoload": {
16+
"psr-0": { "Hamcrest_": "Hamcrest-1.1.0/" },
17+
"files": ["Hamcrest-1.1.0/Hamcrest/Hamcrest.php"]
18+
}
19+
}
20+
}
21+
],
522
"autoload": {
623
"psr-0": {
724
"Barberry": "library/"
@@ -11,5 +28,9 @@
1128
"php": ">=5.3.3",
1229
"barberry/interfaces": "dev-master"
1330
},
14-
"minimum-stability": "dev"
31+
"require-dev": {
32+
"mockery/mockery": "0.7.2",
33+
"phpunit/phpunit": "3.7.1",
34+
"hamcrest/hamcrest": "1.1.0"
35+
}
1536
}

phpunit

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
./vendor/bin/phpunit $*

test/phpunit.xml phpunit.xml

+9-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<phpunit backupGlobals="false"
22
backupStaticAttributes="false"
3-
bootstrap="test_bootstrap.php"
3+
bootstrap="test/test_bootstrap.php"
44
cacheTokens="true"
55
colors="true"
66
convertErrorsToExceptions="true"
@@ -18,11 +18,18 @@
1818
strict="false"
1919
verbose="false">
2020
<listeners>
21-
<listener class="\Mockery\Adapter\Phpunit\TestListener" file="Mockery/Adapter/Phpunit/TestListener.php"> </listener>
21+
<listener class="\Mockery\Adapter\Phpunit\TestListener"
22+
file="vendor/mockery/mockery/library/Mockery/Adapter/Phpunit/TestListener.php"> </listener>
2223
</listeners>
2324

2425
<php>
2526
<env name="APPLICATION_ENV" value="testing"/>
2627
</php>
2728

29+
<testsuites>
30+
<testsuite>
31+
<directory>test</directory>
32+
</testsuite>
33+
</testsuites>
34+
2835
</phpunit>

0 commit comments

Comments
 (0)