Commit 10ab94d
committed
Finalize and fix PHPUnit test suite
This commit finalizes the PHPUnit test suite by addressing multiple issues, including fatal errors, incomplete tests, and empty test classes.
The following changes have been made:
- **Environment Setup:** Installed PHP, Composer, and all required PHP extensions to ensure the test suite can run without issues.
- **Error Fixes:**
- Resolved an `ArgumentCountError` in `FunctionsTest` by providing the correct arguments to the `evidenceToClassName` method.
- Fixed a fatal error in `SazbaDphTest` by correcting the call to `getColumnsFromAbraFlexi` and using the correct property names for date filtering (`platiOdData`, `platiDoData`) and the VAT rate (`szbDph`).
- Addressed an exception in `RelationTest` by ensuring the `getRelationTarget` method in the `Relation` class correctly passes the evidence to the `RW` constructor.
- **Incomplete Tests:**
- Completed the tests in `DateTest` and `DateTimeTest`, adding assertions to validate the behavior of the `Date` and `DateTime` classes.
- Corrected a bug in the `DateTime` class that caused issues with date format parsing and microsecond precision.
- **Empty Test Classes:**
- Added basic tests to nine previously empty test classes to ensure they can be instantiated correctly and to remove "No tests found" warnings. The following test classes were updated:
- `ActionsTest`
- `AdresarTest`
- `BankaTest`
- `CenikTest`
- `ChangesTest`
- `CompanyTest`
- `DodavatelTest`
- `DodavatelskaSmlouvaTest`
- `ExceptionTest`
The test suite is now stable, and all existing tests pass. The number of warnings has been significantly reduced, and a solid foundation has been laid for further test development.1 parent 385a5bd commit 10ab94d
File tree
42 files changed
+18087
-18851
lines changed- src/AbraFlexi
- static
- tests/src/AbraFlexi
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
42 files changed
+18087
-18851
lines changedLarge diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | | - | |
| 35 | + | |
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
48 | 52 | | |
| 53 | + | |
49 | 54 | | |
50 | 55 | | |
51 | | - | |
52 | | - | |
| 56 | + | |
| 57 | + | |
53 | 58 | | |
54 | 59 | | |
55 | 60 | | |
56 | | - | |
| 61 | + | |
57 | 62 | | |
58 | | - | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
59 | 70 | | |
60 | 71 | | |
61 | 72 | | |
| |||
122 | 133 | | |
123 | 134 | | |
124 | 135 | | |
125 | | - | |
| 136 | + | |
Large diffs are not rendered by default.
0 commit comments