You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* feat:implement_toString_for_result_class
* feat:implement_stop()_to_replace_deprecated_end()
* refactor:replace_ramsey_uuid_with_native_php_functions
* refactor:rename_static_method_from_run()_to_watch()
* refactor:move_timer_status_to_dedicated_Enum_class (#5)
* fix:update_timer_status_constant_with_enum_in_test_cases (#6)
* feat:add_new_methods_in_timetracker (#7)
New methods,
1. isStarted()
2. isStopped()
3. getActiveTimers()
* fix:add_isStopped_check_in_finally_block_to_prevent_duplicate_stop_calls (#8)
* docs:update_README_to_include_new_methods
* feat: add new methods in timetracker (#9)
new methods:
- lap
- getLaps
- pause
- resume
- inspect
* chore: add phpunit cache and coverage folders to .gitignore
* chore: add test workflow for master and dev branches (#10)
* chore: add test workflow for master and dev branches
* remove version field from composer.json
* refactor: restore run() as deprecated alias for backward compatibility (#11)
- Reintroduce run() which was previously removed when adding watch()
- Mark run() as deprecated but keep it fully functional
* docs: add changelog for recent changes (#12)
- Implemented `__toString()` method for the `Result` class, allowing instances to be converted to strings (e.g. `"$result"` now returns the calculated value). (PR #1)
6
+
- Added new `stop()` method to the timer, supporting stopping: (PR #2)
7
+
- a specific timer by ID
8
+
-**or** the **most recently started timer** when no ID is provided.
9
+
- Added new `watch()` static method to replace `run()` for executing and timing callbacks. (PR #4)
10
+
- Added new timer utility methods `isStarted()`, `isStopped()`, and `getActiveTimers()` in `TimeTracker` to inspect active and completed timers. (PR #7)
11
+
- Added new timer utility methods `lap()`, `getLaps()`, `pause()`, `resume()`, and `inspect()` in `TimeTracker`. (PR #9)
12
+
13
+
### Changed
14
+
- Replaced `ramsey/uuid` with native PHP functions (`bin2hex(random_bytes(16))`) for generating random IDs. (PR #3)
15
+
- Removed the `ramsey/uuid` dependency as it is no longer required. (PR #3)
16
+
- Replaced `STATUS_*` string constants with a dedicated `TimerStatus` enum. (PR #5)
17
+
18
+
### Fixed
19
+
- Prevent duplicate `stop()` calls in `watch()` by adding an `isStopped()` check in the `finally` block. (RP #8)
20
+
21
+
### Deprecated
22
+
- Marked `end()` as deprecated. It still works for backward compatibility but will be removed in a future major release. (PR #2)
23
+
- Marked `run()` as deprecated. It still works for backward compatibility but will be removed in a future major release. (PR #4)
0 commit comments