fix phpunit tests

This commit is contained in:
DavidBadura 2015-12-26 11:47:51 +00:00
parent 3aaa6492dd
commit 79f779e520
3 changed files with 5 additions and 4 deletions

View File

@ -73,12 +73,12 @@ class DependsHandler implements SubscribingHandlerInterface
$list[] = $task->getUuid(); $list[] = $task->getUuid();
} }
return $visitor->visitString(implode(',', $list), $type, $context); return $visitor->visitArray($list, $type, $context);
} }
/** /**
* @param VisitorInterface $visitor * @param VisitorInterface $visitor
* @param string $data * @param array $data
* @param array $type * @param array $type
* @return ArrayCollection * @return ArrayCollection
*/ */
@ -90,7 +90,7 @@ class DependsHandler implements SubscribingHandlerInterface
$tasks = []; $tasks = [];
foreach (explode(',', $data) as $uuid) { foreach ($data as $uuid) {
$tasks[] = $this->taskManager->getReference($uuid); $tasks[] = $this->taskManager->getReference($uuid);
} }

View File

@ -274,6 +274,7 @@ class Task
if (false !== $key = array_search($tag, $this->tags)) { if (false !== $key = array_search($tag, $this->tags)) {
unset($this->tags[$key]); unset($this->tags[$key]);
$this->tags = array_values($this->tags);
} }
} }

View File

@ -67,7 +67,7 @@ class Taskwarrior
$rcOptions $rcOptions
); );
if (version_compare($this->version(), '2.5.0.beta2') < 0) { if (version_compare($this->version(), '2.5.0') < 0) {
throw new TaskwarriorException(sprintf("Taskwarrior version %s isn't supported", $this->version())); throw new TaskwarriorException(sprintf("Taskwarrior version %s isn't supported", $this->version()));
} }