2020#[Small]
2121final class IssueTriggerTest extends TestCase
2222{
23+ public function testCanBeTest (): void
24+ {
25+ $ trigger = IssueTrigger::test ();
26+
27+ $ this ->assertTrue ($ trigger ->isTest ());
28+ $ this ->assertTrue ($ trigger ->isSelf ());
29+ $ this ->assertFalse ($ trigger ->isDirect ());
30+ $ this ->assertFalse ($ trigger ->isIndirect ());
31+ $ this ->assertFalse ($ trigger ->isUnknown ());
32+ $ this ->assertSame ('issue triggered by test code ' , $ trigger ->asString ());
33+ }
34+
2335 public function testCanBeSelf (): void
2436 {
2537 $ trigger = IssueTrigger::self ();
2638
2739 $ this ->assertTrue ($ trigger ->isSelf ());
40+ $ this ->assertFalse ($ trigger ->isTest ());
2841 $ this ->assertFalse ($ trigger ->isDirect ());
2942 $ this ->assertFalse ($ trigger ->isIndirect ());
3043 $ this ->assertFalse ($ trigger ->isUnknown ());
@@ -36,6 +49,7 @@ public function testCanBeDirect(): void
3649 $ trigger = IssueTrigger::direct ();
3750
3851 $ this ->assertTrue ($ trigger ->isDirect ());
52+ $ this ->assertFalse ($ trigger ->isTest ());
3953 $ this ->assertFalse ($ trigger ->isSelf ());
4054 $ this ->assertFalse ($ trigger ->isIndirect ());
4155 $ this ->assertFalse ($ trigger ->isUnknown ());
@@ -47,6 +61,7 @@ public function testCanBeIndirect(): void
4761 $ trigger = IssueTrigger::indirect ();
4862
4963 $ this ->assertTrue ($ trigger ->isIndirect ());
64+ $ this ->assertFalse ($ trigger ->isTest ());
5065 $ this ->assertFalse ($ trigger ->isSelf ());
5166 $ this ->assertFalse ($ trigger ->isDirect ());
5267 $ this ->assertFalse ($ trigger ->isUnknown ());
@@ -57,6 +72,7 @@ public function testCanBeUnknown(): void
5772 {
5873 $ trigger = IssueTrigger::unknown ();
5974
75+ $ this ->assertFalse ($ trigger ->isTest ());
6076 $ this ->assertFalse ($ trigger ->isSelf ());
6177 $ this ->assertFalse ($ trigger ->isDirect ());
6278 $ this ->assertFalse ($ trigger ->isIndirect ());
0 commit comments