Skip to content

Commit 4e054a5

Browse files
author
T_S_V
committed
Migration to Creator V2 - implemented API controller
1 parent 8d1a9be commit 4e054a5

22 files changed

+3209
-222
lines changed

.env.test

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# define your env variables for the test env here
2+
KERNEL_CLASS='App\Kernel'
3+
APP_SECRET='$ecretf0rt3st'
4+
SYMFONY_DEPRECATIONS_HELPER=999999
5+
PANTHER_APP_ENV=panther
6+
PANTHER_ERROR_SCREENSHOT_DIR=./var/error-screenshots

.gitignore

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,13 @@
1010
###< symfony/framework-bundle ###
1111

1212
.vscode
13+
14+
###> symfony/phpunit-bridge ###
15+
.phpunit.result.cache
16+
/phpunit.xml
17+
###< symfony/phpunit-bridge ###
18+
19+
###> phpunit/phpunit ###
20+
/phpunit.xml
21+
.phpunit.result.cache
22+
###< phpunit/phpunit ###

bin/phpunit

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/usr/bin/env php
2+
<?php
3+
4+
if (!ini_get('date.timezone')) {
5+
ini_set('date.timezone', 'UTC');
6+
}
7+
8+
if (is_file(dirname(__DIR__).'/vendor/phpunit/phpunit/phpunit')) {
9+
define('PHPUNIT_COMPOSER_INSTALL', dirname(__DIR__).'/vendor/autoload.php');
10+
require PHPUNIT_COMPOSER_INSTALL;
11+
PHPUnit\TextUI\Command::main();
12+
} else {
13+
if (!is_file(dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit.php')) {
14+
echo "Unable to find the `simple-phpunit.php` script in `vendor/symfony/phpunit-bridge/bin/`.\n";
15+
exit(1);
16+
}
17+
18+
require dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-phpunit.php';
19+
}

composer.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
"symfony/flex": "^2",
1616
"symfony/framework-bundle": "6.0.*",
1717
"symfony/runtime": "6.0.*",
18+
"symfony/twig-bundle": "6.0.*",
1819
"symfony/yaml": "6.0.*"
1920
},
2021
"config": {
@@ -49,6 +50,7 @@
4950
},
5051
"scripts": {
5152
"start": "php -S localhost:8000 -t public",
53+
"dev": "php -dxdebug.mode=debug -dxdebug.start_with_request=yes -S localhost:8000 -t public",
5254
"test": "phpunit",
5355
"auto-scripts": {
5456
"cache:clear": "symfony-cmd",
@@ -69,5 +71,11 @@
6971
"allow-contrib": false,
7072
"require": "6.0.*"
7173
}
74+
},
75+
"require-dev": {
76+
"phpunit/phpunit": "^9.5",
77+
"symfony/browser-kit": "6.0.*",
78+
"symfony/css-selector": "6.0.*",
79+
"symfony/phpunit-bridge": "^6.0"
7280
}
73-
}
81+
}

0 commit comments

Comments
 (0)