Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: replace byComponent "by" By.directive & rm getComponentSelector #896

Merged
merged 2 commits into from
Nov 29, 2024

Conversation

davidlj95
Copy link
Owner

@davidlj95 davidlj95 commented Nov 29, 2024

It does the same! However, our util was flakier, as it looked by the component selector. There have been some talking around to remove selectors. So using the DI system as By.directive does to look for the item is a stronger approach.

Then, getComponentSelector is only used by the test helper ensuring content projection is performed for the component. However, can get rid of that by specifying a custom selector for the component under test using TestBed.overrideComponent. So doing that and removing that function.

Finally, isClass can be removed as there are no usages of it

@davidlj95 davidlj95 enabled auto-merge (squash) November 29, 2024 12:02
Copy link
Owner Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

Copy link

codecov bot commented Nov 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.65%. Comparing base (acde337) to head (9221a4a).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #896      +/-   ##
==========================================
+ Coverage   96.71%   97.65%   +0.94%     
==========================================
  Files         124      122       -2     
  Lines         609      598      -11     
  Branches       66       62       -4     
==========================================
- Hits          589      584       -5     
+ Misses         16       10       -6     
  Partials        4        4              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@davidlj95 davidlj95 changed the title chore: replace byComponent "by" By.directive chore: replace byComponent "by" By.directive & rm getComponentSelector Nov 29, 2024
@davidlj95 davidlj95 merged commit 0ced2c7 into main Nov 29, 2024
15 checks passed
@davidlj95 davidlj95 deleted the stacked/chore-remove-bycomponent-helper branch November 29, 2024 12:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant