Skip to content

feature: Callable readonly#1150

Merged
adrianthedev merged 2 commits into
avo-hq:mainfrom
rickychilcott:feature/callable-readonly
Aug 19, 2022
Merged

feature: Callable readonly#1150
adrianthedev merged 2 commits into
avo-hq:mainfrom
rickychilcott:feature/callable-readonly

Conversation

@rickychilcott

@rickychilcott rickychilcott commented Aug 18, 2022

Copy link
Copy Markdown
Contributor

Description

This adds support for making the readonly field take a proc, just like required (implemented in #955)

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works

With support from @ncsmith24

@qlty-cloud-legacy

Copy link
Copy Markdown

Code Climate has analyzed commit 0ee683a and detected 0 issues on this pull request.

View more on Code Climate.

@rickychilcott rickychilcott changed the title Callable readonly feature: Callable readonly Aug 18, 2022
@codecov

codecov Bot commented Aug 18, 2022

Copy link
Copy Markdown

Codecov Report

Base: 94.18% // Head: 94.27% // Increases project coverage by +0.08% 🎉

Coverage data is based on head (0ee683a) compared to base (fed8189).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1150      +/-   ##
==========================================
+ Coverage   94.18%   94.27%   +0.08%     
==========================================
  Files         530      549      +19     
  Lines       10560    10967     +407     
==========================================
+ Hits         9946    10339     +393     
- Misses        614      628      +14     
Impacted Files Coverage Δ
...ents/avo/fields/belongs_to_field/edit_component.rb 100.00% <100.00%> (ø)
lib/avo/fields/base_field.rb 95.51% <100.00%> (+0.02%) ⬆️
lib/avo/fields/concerns/is_readonly.rb 100.00% <100.00%> (ø)
spec/dummy/app/avo/resources/fish_resource.rb 100.00% <100.00%> (ø)
spec/features/avo/readonly_takes_a_block_spec.rb 100.00% <100.00%> (ø)
spec/features/avo/required_takes_a_block_spec.rb 100.00% <100.00%> (ø)
...ec/dummy/app/controllers/avo/courses_controller.rb 78.94% <0.00%> (-21.06%) ⬇️
.../dummy/app/avo/resources/photo_comment_resource.rb 95.00% <0.00%> (-5.00%) ⬇️
app/controllers/avo/search_controller.rb 92.95% <0.00%> (-3.20%) ⬇️
app/controllers/avo/base_controller.rb 92.18% <0.00%> (-1.22%) ⬇️
... and 51 more

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.

@rickychilcott

Copy link
Copy Markdown
Contributor Author

The failing test appears unrelated to me.

@adrianthedev

Copy link
Copy Markdown
Collaborator

This looks good too! Again, I'll do a manual check tmr! Thank you for your contribution!

@adrianthedev adrianthedev merged commit b0a533b into avo-hq:main Aug 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants