Skip to content
Snippets Groups Projects
Verified Commit 5d544f1a authored by Damien's avatar Damien
Browse files

FEAT #7892 Move test to app root

parent de34276d
No related branches found
No related tags found
No related merge requests found
Showing
with 35 additions and 46 deletions
......@@ -7,7 +7,7 @@ apps/maarch_entreprise/xml/log4php.xml
.phplint.yml
*.log
xdelete.sh
core/Test/build/
test/build/
apps/maarch_entreprise/js/angular/main.bundle.js
modules/convert/batch/scripts/launch_fulltext_letterbox.sh
modules/convert/batch/scripts/launch_convert_letterbox.sh
......
<?xml version="1.0" encoding="UTF-8"?>
<phpunit colors="true" bootstrap="core/Test/define.php">
<phpunit colors="true" bootstrap="test/define.php">
<testsuites>
<testsuite name="Maarch Core Test Suite">
<!--directory>core/Test</directory-->
<file>core/Test/ActionControllerTest.php</file>
<file>core/Test/AutocompleteControllerTest.php</file>
<file>core/Test/BasketControllerTest.php</file>
<file>core/Test/ContactControllerTest.php</file>
<file>core/Test/ContactGroupControllerTest.php</file>
<file>core/Test/ContactTypeControllerTest.php</file>
<file>core/Test/DocserverControllerTest.php</file>
<file>core/Test/DoctypeControllerTest.php</file>
<file>core/Test/EntityControllerTest.php</file>
<file>core/Test/GroupControllerTest.php</file>
<file>core/Test/ListTemplateControllerTest.php</file>
<file>core/Test/NotificationControllerTest.php</file>
<file>core/Test/NotificationScheduleControllerTest.php</file>
<file>core/Test/ParameterControllerTest.php</file>
<file>core/Test/PriorityControllerTest.php</file>
<file>core/Test/ReportControllerTest.php</file>
<file>core/Test/ResControllerTest.php</file>
<file>core/Test/StatusControllerTest.php</file>
<file>core/Test/UserControllerTest.php</file>
<file>core/Test/VersionUpdateControllerTest.php</file>
<file>core/Test/CoreControllerTest.php</file>
<file>core/Test/TemplateControllerTest.php</file>
<!--<file>modules/convert/Test/ProcessConvertTest.php</file>-->
<!--<file>modules/convert/Test/ProcessFulltextTest.php</file>-->
<!--<file>modules/convert/Test/ProcessManageConvertTest.php</file>-->
<!--<file>modules/convert/Test/ProcessThumbnailsTest.php</file>-->
<testsuite name="Maarch Test Suite">
<!--directory>test</directory-->
<file>test/ActionControllerTest.php</file>
<file>test/AutocompleteControllerTest.php</file>
<file>test/BasketControllerTest.php</file>
<file>test/ContactControllerTest.php</file>
<file>test/ContactGroupControllerTest.php</file>
<file>test/ContactTypeControllerTest.php</file>
<file>test/DocserverControllerTest.php</file>
<file>test/DoctypeControllerTest.php</file>
<file>test/EntityControllerTest.php</file>
<file>test/GroupControllerTest.php</file>
<file>test/ListTemplateControllerTest.php</file>
<file>test/NotificationControllerTest.php</file>
<file>test/NotificationScheduleControllerTest.php</file>
<file>test/ParameterControllerTest.php</file>
<file>test/PriorityControllerTest.php</file>
<file>test/ReportControllerTest.php</file>
<file>test/ResControllerTest.php</file>
<file>test/StatusControllerTest.php</file>
<file>test/UserControllerTest.php</file>
<file>test/VersionUpdateControllerTest.php</file>
<file>test/CoreControllerTest.php</file>
<file>test/TemplateControllerTest.php</file>
<!-- The last one should be history -->
<file>core/Test/HistoryControllerTest.php</file>
<file>test/HistoryControllerTest.php</file>
</testsuite>
</testsuites>
<filter>
<whitelist>
<directory suffix="Test.php">core/Test</directory>
<directory suffix=".php">src</directory>
<!--<directory suffix=".php">modules/convert/Controllers</directory>-->
<!--<directory suffix=".php">modules/convert/Models</directory>-->
</whitelist>
</filter>
<logging>
<log type="coverage-clover" target="core/Test/build/tests-clover.xml"/>
<log type="junit" target="core/Test/build/tests-phpunit.xml" logIncompleteSkipped="false"/>
<log type="coverage-html" target="core/Test/build" lowUpperBound="35" highLowerBound="70"/>
<log type="coverage-clover" target="test/build/tests-clover.xml"/>
<log type="junit" target="test/build/tests-phpunit.xml" logIncompleteSkipped="false"/>
<log type="coverage-html" target="test/build" lowUpperBound="35" highLowerBound="70"/>
</logging>
</phpunit>
File moved
File moved
File moved
File moved
File moved
File moved
File moved
File moved
......@@ -63,10 +63,9 @@ class NotificationScheduleControllerTest extends TestCase
$responseBody = json_decode((string) $response->getBody());
// CREATE FAIL
$aArgs = [];
$aArgs = $responseBody->crontab;
$corePath = dirname(__FILE__, 3).'/';
$corePath = dirname(__FILE__, 2).'/';
$newCrontab = [
'm' => 12,
'h' => 23,
......@@ -88,10 +87,9 @@ class NotificationScheduleControllerTest extends TestCase
$environment = \Slim\Http\Environment::mock(['REQUEST_METHOD' => 'POST']);
$request = \Slim\Http\Request::createFromEnvironment($environment);
$aArgs = [];
$aArgs = $responseBody->crontab;
$corePath = dirname(__FILE__, 3).'/';
$corePath = dirname(__FILE__, 2).'/';
$newCrontab = [
'm' => 12,
'h' => 23,
......@@ -138,10 +136,9 @@ class NotificationScheduleControllerTest extends TestCase
$environment = \Slim\Http\Environment::mock(['REQUEST_METHOD' => 'POST']);
$request = \Slim\Http\Request::createFromEnvironment($environment);
$aArgs = [];
$aArgs = $responseBody->crontab;
$corePath = dirname(__FILE__, 3).'/';
$corePath = dirname(__FILE__, 2).'/';
$aArgs[count($aArgs) - 1] = [
'm' => 35,
......@@ -181,11 +178,10 @@ class NotificationScheduleControllerTest extends TestCase
$response = $NotificationScheduleController->get($request, new \Slim\Http\Response());
$responseBody = json_decode((string) $response->getBody());
$aArgs = [];
$aArgs = $responseBody->crontab;
foreach ($aArgs as $id => $value) {
if ($value->cmd == dirname(__FILE__, 3).'/'.'modules/notifications/batch/scripts/notification_testtu.sh') {
if ($value->cmd == dirname(__FILE__, 2).'/'.'modules/notifications/batch/scripts/notification_testtu.sh') {
$aArgs[$id]->state = 'hidden';
}
}
......@@ -200,11 +196,10 @@ class NotificationScheduleControllerTest extends TestCase
$this->assertSame('Problem with crontab', $responseBodyFail->errors);
// DELETE
$aArgs = [];
$aArgs = $responseBody->crontab;
foreach ($aArgs as $id => $value) {
if ($value->cmd == dirname(__FILE__, 3).'/'.'modules/notifications/batch/scripts/notification_testtu.sh') {
if ($value->cmd == dirname(__FILE__, 2).'/'.'modules/notifications/batch/scripts/notification_testtu.sh') {
$aArgs[$id]->state = 'deleted';
}
}
......
File moved
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment