44
55use DateInterval ;
66use DateTime ;
7+ use Exception ;
78use JiraCloud \Sprint \Sprint ;
89use JiraCloud \Sprint \SprintService ;
910use 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