-
Notifications
You must be signed in to change notification settings - Fork 122
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
fix: add pebble log targets and checks to testing plan #1111
fix: add pebble log targets and checks to testing plan #1111
Conversation
Thanks! My bad for missing log targets in #1074. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few comments here. Mainly small things, and the test should move.
Additionally, type checking and tests are failing.
ops/testing.py
Outdated
for key in sorted(self._layers.keys()): | ||
layer = self._layers[key] | ||
for name, service in layer.services.items(): | ||
# TODO: (jam) 2021-04-07 have a way to merge existing services | ||
services[name] = service | ||
services[name] = service.to_dict() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, not an issue with this PR, but looking at this code made me realize we're not even attempting to combine layers correctly here. We already have the code to combine a layer (in _TestingPebbleClient.add_layer
), we just need to use it here as well.
We also have pebble.Service._merge
, but we'll need similar _merge
methods on pebble.Check
and pebble.LogTarget
and update appropriately to merge those blocks as well.
I think we can leave it "broken" in this PR (it's already broken now, so this doesn't make it worse), but I've opened #1112 to track.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the updates. Couple of small changes requested, and then we're good to go.
4168e63
to
269a0e7
Compare
Issue: adding a layer with checks or log-targets isn't reflected in the plan you obtain when testing through get_plan()
solution: make it reflect