Commit graph

55 commits

Author SHA1 Message Date
d15f30bcbf
test(UuidHelper): update unit tests for UUID version checks
Refactor test descriptions for clarity and consistency.
2026-08-13 13:06:01 +02:00
ab031e8d76
test(CodingStandards): refactor test file retrieval logic
Updated test file retrieval to use a dedicated function for improved clarity and maintainability.
2026-08-13 12:58:29 +02:00
39d394b7fb
test(Employee): add feature tests for employee endpoints
- Implement tests for retrieving employee details and listing employees.
- Validate responses against OpenAPI specifications.
2026-08-13 12:55:38 +02:00
3daeaccb4e
test(RootTest): add test for successful response on root URL
This test verifies that the root URL returns a 200 status code.
2026-08-13 12:49:33 +02:00
cc7a629193
test(UsecaseBuilder): add unit tests for UsecaseBuilder functionality
This commit introduces unit tests for the UsecaseBuilder and UsecaseExecutionBuilder, ensuring proper behavior when building and executing use cases.
2026-08-13 12:47:39 +02:00
ccba793b4c
test(EntityId): add unit tests for EntityId instantiation
Includes tests for valid UUID and handling of empty string.
2026-08-13 12:47:18 +02:00
52d0e6f0fd
test(ApiExceptionDispatcher): add integration tests for exception handling
Added integration tests for ApiExceptionDispatcher to ensure proper handling of exceptions
for various API request scenarios, including JSON acceptance and unversioned requests.
2026-08-13 12:34:44 +02:00
8e96abc88d
fix(ApiExceptionRenderer): update response for ValidationException
Changed the response status and title for ValidationException from 400 to 422 to align with HTTP standards.
2026-08-13 12:34:32 +02:00
b3f02510b5
docs: update README and add Exceptions documentation
Added a section for Exception Management in README and created a new document detailing exception handling and HTTP status codes.
2026-08-13 12:34:12 +02:00
b7c5c98128
fix(ApiExceptionRenderer): change title for ValidationException response
Update the title for the ValidationException response to accurately reflect the error type.
2026-08-13 12:26:56 +02:00
985fcedb04
test(WebExceptionRenderer): add tests for rendering exceptions
Add tests to verify the behavior of WebExceptionRenderer for NotFoundException and unhandled exceptions.
2026-08-13 12:18:22 +02:00
52d121085a
chore: exclude views directory from PHPUnit tests
This change ensures that the views directory is not included in the test coverage.
2026-08-13 12:18:07 +02:00
3ba74409ff
test(ValueObjects): add unit tests for BrandCode, EstablishmentCode, IncoCompoId, IncoId, ServiceId, and SiteId value objects
Add comprehensive unit tests to validate the behavior of various value objects.
2026-08-13 12:10:53 +02:00
742476bdcb
test(ArcadiaEmployeeId): add covers declaration for tests 2026-08-13 12:03:16 +02:00
90d7bfdf37
test(Employee): add unit tests for Employee entity 2026-08-13 12:03:09 +02:00
31b83970b5
test: remove ExampleTest.php as it is no longer needed
This test file was deleted to clean up the test suite.
2026-08-13 12:02:49 +02:00
41dbb04963
test(Architecture): ensure all Unit and Integration tests declare covers()
Added a test to verify that every Unit and Integration test file contains a covers() declaration.
2026-08-13 12:02:43 +02:00
f8b5722a78
test(ArcadiaEmployeeId): add unit tests for ArcadiaEmployeeId value object 2026-08-13 11:57:52 +02:00
0111ee2ac4
refactor(Employees): remove BaseEnum trait and clean up EmployeeSortColumn
This change simplifies the EmployeeSortColumn enum by removing the BaseEnum trait,
which is no longer needed.
2026-08-13 11:52:13 +02:00
198da8a11c
test(Pagination): add unit tests for Pagination value object 2026-08-13 11:50:16 +02:00
8c0d139ad3
docs(README): update table of contents and add testing section
docs(TEST): add testing strategy and organization document
2026-08-13 11:50:11 +02:00
84e59314a0
test(Architecture): add namespaces to architecture test files and create integration test suite
- Added namespaces to various architecture test files for consistency.
- Created a new integration test suite in phpunit.xml.
2026-08-13 11:25:08 +02:00
fed1916b24
test(UuidHelper): add unit tests for UUID version verification 2026-08-13 10:29:05 +02:00
eacfd828f0
test(DateHelper): add integration tests for date parsing and formatting
This commit introduces integration tests for the DatesHelper class,
ensuring correct functionality for date parsing, range verification,
and RFC3339 formatting.
2026-08-13 10:24:11 +02:00
57756ce6ae
test(UuidHelper): add unit tests for UUID version verification
Includes tests for checking if UUIDs are v4 or v7 and retrieving their version.
2026-08-13 10:24:05 +02:00
40c360f766
ci: add test coverage command to composer scripts
This change introduces a new command for running tests with coverage
threshold set to a minimum of 85%.
2026-08-13 10:10:15 +02:00
554e4002df
refactor(api): update Employee request handling and remove toInput method
Refactor EmployeeShowRequest and EmployeesIndexRequest to improve clarity and maintainability.
2026-08-13 09:55:27 +02:00
6c7c782a1d
feat(api): add Ping and Root API documentation files
fix(api): update sequence number for Employees folder
2026-08-13 09:35:16 +02:00
b2c11a52ad
refactor(api): restructure API routes and improve organization
- Group employee routes under a prefix for better clarity.
- Remove unnecessary blank lines and improve code formatting.
2026-08-13 09:35:09 +02:00
3208556047
fix(robots): update disallow rule for web crawlers
Ensure that all web crawlers are disallowed from accessing the site.
2026-08-12 17:42:02 +02:00
d9329aca92
feat(errors): add detailed error documentation pages
- Implemented views for error codes 400, 404, 422, 429, 500, and 503.
- Updated error handling to use numeric codes instead of enum.
- Enhanced error messages and resolution steps for better user guidance.
2026-08-12 17:40:18 +02:00
699cdf7f8e
fix(api): correct condition for API request handling
Updated the condition to include 'api' in the request check.
2026-08-12 17:32:19 +02:00
33f3aaf37f
fix(api): correct condition for JSON request handling
Ensure proper handling of requests that expect JSON responses.
2026-08-12 17:30:36 +02:00
fd284db1c2
fix(api): correct JSON rendering condition for API requests
Updated the condition to ensure JSON responses are rendered for both 'api/*' and 'api' requests.
2026-08-12 17:30:22 +02:00
04243860ce
refactor(api): simplify exception handling in app configuration
Removed custom exception handling logic and replaced it with a reference to the existing exceptions file.
2026-08-12 17:26:31 +02:00
e92b042906
feat(env): add throttle settings for web and API
Added THROTTLE_WEB and THROTTLE_API_V1 settings to the environment configuration.
2026-08-12 17:26:25 +02:00
caa4bb0919
feat(api): restore ping endpoint and add rate limit responses
Restores the /ping endpoint for health checks and adds
429 Too Many Requests response handling to improve API robustness.
2026-08-12 17:26:17 +02:00
a93fde3a3c
feat(api): implement rate limiting and error handling
- Added rate limiting for web and API requests.
- Introduced custom error handling for "Too Many Requests" response.
- Created view for "Too Many Requests" error documentation.
2026-08-12 17:25:45 +02:00
f62ea18e75
feat(api): add health check endpoint
This adds a new /ping endpoint to verify API functionality.
2026-08-12 17:12:35 +02:00
a738fed493
refactor(api): restructure root response to include versions 2026-08-12 17:11:37 +02:00
c5867c7926
refactor(layout): replace main layout with minimal layout
Updated the layout structure to use a minimal design, enhancing the overall presentation of the API status page.
2026-08-12 17:11:27 +02:00
cfea429840
style(api): update response message for root URL
Clarifies the message presented to users when accessing the API root.
2026-08-12 17:05:35 +02:00
0cd539c180
test(architecture): add rules to prevent Presenters and Views
Ensure that the Application layer does not contain Presenters or Views.
2026-08-12 17:01:09 +02:00
6712e06042
docs(README): update API description and architecture details
Added detailed architecture sections and principles of implementation to the README.
2026-08-12 17:00:48 +02:00
2526560e44
docs(responses): clarify error descriptions in OpenAPI spec
Updated descriptions for BadRequest and UnprocessableEntity responses to provide clearer context on validation errors.
2026-08-12 17:00:23 +02:00
31ae87f358
fix(exceptions): correct status code for validation errors
Updated the status code for ValidationException responses from 422 to 400 to align with HTTP standards.
2026-08-12 17:00:15 +02:00
899bb42964
refactor(api): remove ApiClient model 2026-08-12 17:00:06 +02:00
3100643eac
refactor(employees): simplify validation rules for employee requests
Removed regex patterns from validation rules for employeeId, establishment, siteId, and serviceId to streamline input handling.
2026-08-12 17:00:01 +02:00
38ca7ed069
feat(employees): introduce presenters and views for employee data
- Added EmployeeShowPresenter and EmployeeShowView for handling employee details.
- Introduced EmployeesIndexPresenter and EmployeesIndexView for paginated employee listings.
2026-08-12 16:59:50 +02:00
43a568ef5a
refactor(employees): replace native assert with Webmozart\Assert
Updated assertions in FindEmployee, FindAllEmployees, and Output classes
to use Webmozart\Assert for better type safety and consistency.
2026-08-12 16:56:13 +02:00