summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2015-06-20 11:19:44 -0400
committerFrederic Guillot <fred@kanboard.net>2015-06-20 11:19:44 -0400
commitd3f789764dcf90923a0d0f639dd2ee56b1177f84 (patch)
treee71980ab55941f902ffd94f50cc7a35360696483 /tests
parentcb0916d10e4a42a62f0ac8c69ecb4b7a15f398b4 (diff)
Change travis-ci configuration
Diffstat (limited to 'tests')
-rw-r--r--tests/php.ini2
-rw-r--r--tests/units/Base.php2
-rw-r--r--tests/units/TaskCreationTest.php2
-rw-r--r--tests/units/TaskStatusTest.php4
4 files changed, 5 insertions, 5 deletions
diff --git a/tests/php.ini b/tests/php.ini
new file mode 100644
index 00000000..7079a4e6
--- /dev/null
+++ b/tests/php.ini
@@ -0,0 +1,2 @@
+short_open_tag = On
+date.timezone = UTC \ No newline at end of file
diff --git a/tests/units/Base.php b/tests/units/Base.php
index d2190c32..1bbd62f8 100644
--- a/tests/units/Base.php
+++ b/tests/units/Base.php
@@ -9,8 +9,6 @@ use Symfony\Component\Stopwatch\Stopwatch;
use SimpleLogger\Logger;
use SimpleLogger\File;
-date_default_timezone_set('UTC');
-
class FakeHttpClient
{
private $url = '';
diff --git a/tests/units/TaskCreationTest.php b/tests/units/TaskCreationTest.php
index 986f1eb1..b3f001c7 100644
--- a/tests/units/TaskCreationTest.php
+++ b/tests/units/TaskCreationTest.php
@@ -94,7 +94,7 @@ class TaskCreationTest extends Base
$this->assertEquals('', $task['reference']);
$this->assertEquals(time(), $task['date_creation'], 'Wrong timestamp', 1);
- $this->assertEquals(time(), $task['date_modification'], 'Wrog timestamp', 1);
+ $this->assertEquals(time(), $task['date_modification'], 'Wrong timestamp', 1);
$this->assertEquals(0, $task['date_due']);
$this->assertEquals(0, $task['date_completed']);
$this->assertEquals(0, $task['date_started']);
diff --git a/tests/units/TaskStatusTest.php b/tests/units/TaskStatusTest.php
index b62ae560..5c59698b 100644
--- a/tests/units/TaskStatusTest.php
+++ b/tests/units/TaskStatusTest.php
@@ -29,7 +29,7 @@ class TaskStatusTest extends Base
$this->assertNotEmpty($task);
$this->assertEquals(Task::STATUS_OPEN, $task['is_active']);
$this->assertEquals(0, $task['date_completed']);
- $this->assertEquals(time(), $task['date_modification']);
+ $this->assertEquals(time(), $task['date_modification'], '', 1);
// We close the task
@@ -54,7 +54,7 @@ class TaskStatusTest extends Base
$this->assertNotEmpty($task);
$this->assertEquals(Task::STATUS_OPEN, $task['is_active']);
$this->assertEquals(0, $task['date_completed']);
- $this->assertEquals(time(), $task['date_modification'], 1);
+ $this->assertEquals(time(), $task['date_modification'], '', 1);
$called = $this->container['dispatcher']->getCalledListeners();
$this->assertArrayHasKey('task.close.TaskStatusTest::onTaskClose', $called);