Skip to content

Improve callable rule#343

Merged
arogachev merged 17 commits into
masterfrom
improve-callable-rule
Oct 20, 2022
Merged

Improve callable rule#343
arogachev merged 17 commits into
masterfrom
improve-callable-rule

Conversation

@xepozz

@xepozz xepozz commented Oct 15, 2022

Copy link
Copy Markdown
Member
Q A
Is bugfix?
New feature? ✔️
Breaks BC?
Fix #327
  • Added ability to run non-static methods
  • Static methods are still supported

@xepozz xepozz added the status:code review The pull request needs review. label Oct 15, 2022
@xepozz xepozz requested a review from a team October 15, 2022 09:25
@codecov

codecov Bot commented Oct 15, 2022

Copy link
Copy Markdown

Codecov Report

Base: 95.72% // Head: 95.67% // Decreases project coverage by -0.05% ⚠️

Coverage data is based on head (c4f748f) compared to base (9fd61f1).
Patch coverage: 87.50% of modified lines in pull request are covered.

❗ Current head c4f748f differs from pull request most recent head 1812f3c. Consider uploading reports for the commit 1812f3c to get more accurate results

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #343      +/-   ##
============================================
- Coverage     95.72%   95.67%   -0.06%     
- Complexity      600      601       +1     
============================================
  Files            73       73              
  Lines          1428     1433       +5     
============================================
+ Hits           1367     1371       +4     
- Misses           61       62       +1     
Impacted Files Coverage Δ
src/Rule/Callback.php 77.77% <87.50%> (+0.50%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Comment thread tests/DataSet/ObjectDataSetTest.php
Comment thread tests/Rule/CallbackTest.php Outdated
Comment thread src/Rule/Callback.php
@arogachev arogachev linked an issue Oct 17, 2022 that may be closed by this pull request
Comment thread tests/DataSet/ObjectDataSetTest.php
Comment thread tests/Rule/CallbackTest.php Outdated
Comment thread src/Rule/Callback.php
Comment thread tests/Rule/CallbackTest.php Outdated
Comment thread tests/DataSet/ObjectDataSetTest.php
Comment thread src/Rule/Callback.php

@arogachev arogachev left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@arogachev arogachev added the type:enhancement Enhancement label Oct 18, 2022
@xepozz xepozz requested a review from a team October 19, 2022 22:21
Comment thread tests/Rule/CallbackTest.php Outdated
@arogachev arogachev merged commit ea4c47f into master Oct 20, 2022
@arogachev arogachev deleted the improve-callable-rule branch October 20, 2022 06:46
arogachev added a commit that referenced this pull request Oct 20, 2022
* Fix rules serialization

* Apply fixes from StyleCI

* Add test for iterable rules

* Fix error message

* Apply fixes from StyleCI

* Improve callable rule (#343)

* Add ability to run non-static closures

* Apply fixes from StyleCI

* Fix tests

* Apply fixes from StyleCI

* Improve method check

* Apply fixes from StyleCI

* Check property before the use

* Collapse test

* Apply fixes from StyleCI

* Add test for static method

* Apply CR suggestions

* Update tests/Rule/CallbackTest.php

* Apply fixes from StyleCI

Co-authored-by: StyleCI Bot <[email protected]>
Co-authored-by: Alexey Rogachev <[email protected]>

* Fix code coverage

Co-authored-by: StyleCI Bot <[email protected]>
Co-authored-by: Alexey Rogachev <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status:code review The pull request needs review. type:enhancement Enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support for non-static methods in Callback::$method

4 participants