Skip to content

Commit 7e628f2

Browse files
authored
Merge pull request #6 from codemix/refine-test-config
Test against newer PHP versions and use require/autoload-dev
2 parents 5c3648f + 31142fe commit 7e628f2

File tree

6 files changed

+46
-22
lines changed

6 files changed

+46
-22
lines changed

.travis.yml

+4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
language: php
2+
dist: trusty
23
php:
4+
- "7.4"
5+
- "7.3"
6+
- "7.2"
37
- "7.1"
48
- "7.0"
59
- "5.6"

composer.json

+26-18
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,29 @@
11
{
2-
"name": "codemix/yii2-configloader",
3-
"description": "Build configuration arrays from config files and env vars.",
4-
"keywords": ["yii2", "config", "environment"],
5-
"license": "MIT",
6-
"authors": [
7-
{
8-
"name": "Michael Härtl",
9-
"email": "haertl.mike@gmail.com"
10-
}
11-
],
12-
"require": {
13-
"yiisoft/yii2": "*",
14-
"vlucas/phpdotenv": "2.5.*"
15-
},
16-
"autoload": {
17-
"psr-4": {
18-
"codemix\\yii2confload\\": "src/"
19-
}
2+
"name": "codemix/yii2-configloader",
3+
"description": "Build configuration arrays from config files and env vars.",
4+
"keywords": ["yii2", "config", "environment"],
5+
"license": "MIT",
6+
"authors": [
7+
{
8+
"name": "Michael Härtl",
9+
"email": "haertl.mike@gmail.com"
2010
}
11+
],
12+
"require": {
13+
"yiisoft/yii2": "*",
14+
"vlucas/phpdotenv": "2.5.*"
15+
},
16+
"require-dev": {
17+
"phpunit/phpunit": ">4.0 <8"
18+
},
19+
"autoload": {
20+
"psr-4": {
21+
"codemix\\yii2confload\\": "src/"
22+
}
23+
},
24+
"autoload-dev": {
25+
"psr-4": {
26+
"tests\\": "tests"
27+
}
28+
}
2129
}

tests/BootstrapTest.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
<?php
2+
namespace tests;
3+
4+
use \PHPUnit\Framework\TestCase;
25
use codemix\yii2confload\Config;
36

4-
class BootstrapTest extends \PHPUnit\Framework\TestCase
7+
class BootstrapTest extends TestCase
58
{
69
public function testCanBootstrapApplication()
710
{

tests/ConsoleConfigTest.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
<?php
2+
namespace tests;
3+
4+
use \PHPUnit\Framework\TestCase;
25
use codemix\yii2confload\Config;
36

4-
class ConsoleConfigTest extends \PHPUnit\Framework\TestCase
7+
class ConsoleConfigTest extends TestCase
58
{
69
public function testCanGetConfig()
710
{

tests/EnvTest.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
<?php
2+
namespace tests;
3+
4+
use \PHPUnit\Framework\TestCase;
25
use codemix\yii2confload\Config;
36

4-
class EnvTest extends \PHPUnit\Framework\TestCase
7+
class EnvTest extends TestCase
58
{
69
public function testCanInitYiiEnvFromEnvVars()
710
{

tests/WebConfigTest.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
<?php
2+
namespace tests;
3+
4+
use \PHPUnit\Framework\TestCase;
25
use codemix\yii2confload\Config;
36

4-
class WebConfigTest extends \PHPUnit\Framework\TestCase
7+
class WebConfigTest extends TestCase
58
{
69
public function testCanGetConfig()
710
{

0 commit comments

Comments
 (0)