summaryrefslogtreecommitdiff
path: root/tests/units/Action/TaskAssignCurrentUserTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/units/Action/TaskAssignCurrentUserTest.php')
-rw-r--r--tests/units/Action/TaskAssignCurrentUserTest.php7
1 files changed, 2 insertions, 5 deletions
diff --git a/tests/units/Action/TaskAssignCurrentUserTest.php b/tests/units/Action/TaskAssignCurrentUserTest.php
index f8946577..08176b1c 100644
--- a/tests/units/Action/TaskAssignCurrentUserTest.php
+++ b/tests/units/Action/TaskAssignCurrentUserTest.php
@@ -43,19 +43,16 @@ class TaskAssignCurrentUserTest extends Base
public function testExecute()
{
+ $this->container['sessionStorage']->user = array('id' => 5);
+
$action = new TaskAssignCurrentUser($this->container, 1, Task::EVENT_MOVE_COLUMN);
$action->setParam('column_id', 2);
- $_SESSION = array(
- 'user' => array('id' => 5)
- );
// We create a task in the first column
$tc = new TaskCreation($this->container);
$tf = new TaskFinder($this->container);
$p = new Project($this->container);
- $us = new UserSession($this->container);
- $this->assertEquals(5, $us->getId());
$this->assertEquals(1, $p->create(array('name' => 'test')));
$this->assertEquals(1, $tc->create(array('title' => 'test', 'project_id' => 1, 'column_id' => 1)));