77use Awesomized \Checksums \Crc32 ;
88use Awesomized \Checksums \tests \unit \Definitions ;
99use FFI ;
10+ use FFI \Exception ;
1011use PHPUnit \Framework \TestCase ;
1112use Random \RandomException ;
1213
@@ -19,6 +20,7 @@ final class ComputerTest extends TestCase
1920
2021 /**
2122 * @throws \InvalidArgumentException
23+ * @throws Exception
2224 */
2325 protected function setUp (): void
2426 {
@@ -27,11 +29,11 @@ protected function setUp(): void
2729
2830 /**
2931 * @throws \InvalidArgumentException
30- * @throws \FFI\ Exception
32+ * @throws Exception
3133 */
3234 public function testConstructorInvalidLibraryShouldFail (): void
3335 {
34- $ this ->expectException (\InvalidArgumentException ::class);
36+ $ this ->expectException (Exception ::class);
3537
3638 $ ffi = \FFI ::cdef ();
3739
@@ -44,12 +46,13 @@ public function testConstructorInvalidLibraryShouldFail(): void
4446 * @depends testConstructorInvalidLibraryShouldFail
4547 *
4648 * @throws \InvalidArgumentException
49+ * @throws Exception
4750 */
4851 public function testConstructorValidLibraryShouldSucceed (): void
4952 {
5053 $ this ->expectNotToPerformAssertions ();
5154
52- $ ffi = new Crc32 \IsoHdlc \Computer (
55+ new Crc32 \IsoHdlc \Computer (
5356 crc32IsoHdlc: $ this ->ffi ,
5457 );
5558 }
@@ -59,6 +62,7 @@ public function testConstructorValidLibraryShouldSucceed(): void
5962 *
6063 * @throws \InvalidArgumentException
6164 * @throws \RuntimeException
65+ * @throws Exception
6266 */
6367 public function testCalculateHelloWorldShouldSucceed (): void
6468 {
@@ -77,6 +81,7 @@ public function testCalculateHelloWorldShouldSucceed(): void
7781 *
7882 * @throws \InvalidArgumentException
7983 * @throws \RuntimeException
84+ * @throws Exception
8085 */
8186 public function testCalculateFileHelloWorldShouldSucceed (): void
8287 {
@@ -99,6 +104,7 @@ public function testCalculateFileHelloWorldShouldSucceed(): void
99104 * @throws \InvalidArgumentException
100105 * @throws \RuntimeException
101106 * @throws RandomException
107+ * @throws Exception
102108 */
103109 public function testCalculateBinaryDataShouldSucceed (): void
104110 {
@@ -114,6 +120,7 @@ public function testCalculateBinaryDataShouldSucceed(): void
114120 *
115121 * @throws \InvalidArgumentException
116122 * @throws \RuntimeException
123+ * @throws Exception
117124 */
118125 public function testCalculateChunkedDataShouldSucceed (): void
119126 {
@@ -133,6 +140,7 @@ public function testCalculateChunkedDataShouldSucceed(): void
133140 *
134141 * @throws \InvalidArgumentException
135142 * @throws \RuntimeException
143+ * @throws Exception
136144 */
137145 public function testCalculateCheckValueShouldMatch (): void
138146 {
@@ -151,6 +159,7 @@ public function testCalculateCheckValueShouldMatch(): void
151159 *
152160 * @throws \InvalidArgumentException
153161 * @throws \RuntimeException
162+ * @throws Exception
154163 */
155164 public function testComparePhpFunctionKnownValuesShouldMatch (): void
156165 {
0 commit comments