Skip to content

Commit 88bcf38

Browse files
committed
revised SprintService
1 parent 8e06ea2 commit 88bcf38

1 file changed

Lines changed: 7 additions & 8 deletions

File tree

tests/SPrintTest.php

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use DateInterval;
66
use DateTime;
7+
use Exception;
78
use JiraCloud\Sprint\Sprint;
89
use JiraCloud\Sprint\SprintService;
910
use PHPUnit\Framework\TestCase;
@@ -39,8 +40,8 @@ public function create_sprint() : int
3940

4041
return $sprint->id;
4142

42-
} catch (JiraException $e) {
43-
$this->assertTrue(false, 'testSearch Failed : '.$e->getMessage());
43+
} catch (Exception $e) {
44+
$this->fail( 'testSearch Failed : '.$e->getMessage());
4445
}
4546
}
4647

@@ -59,11 +60,10 @@ public function get_sprints(int $sprintId) : int
5960
$sprint = $sps->getSprint($sprintId);
6061

6162
$this->assertNotNull($sprint->name);
62-
Dumper::dump($sprint);
6363

6464
return $sprintId;
65-
} catch (JiraException $e) {
66-
$this->assertTrue(false, 'testSearch Failed : '.$e->getMessage());
65+
} catch (Exception $e) {
66+
$this->fail('testSearch Failed : '.$e->getMessage());
6767
}
6868
}
6969

@@ -82,9 +82,8 @@ public function get_issues_in_sprints(int $sprintId)
8282
$sprint = $sps->getSprintIssues($sprintId);
8383

8484
$this->assertNotNull($sprint);
85-
Dumper::dump($sprint);
86-
} catch (JiraException $e) {
87-
$this->assertTrue(false, 'testSearch Failed : '.$e->getMessage());
85+
} catch (Exception $e) {
86+
$this->fail('testSearch Failed : '.$e->getMessage());
8887
}
8988
}
9089
}

0 commit comments

Comments
 (0)