Improve some testing and setup around configuration.

Review Request #11528 — Created March 16, 2021 and submitted

Information

ReviewBot
release-3.0.x

Reviewers

Recent changes made it easier to replace the worker configuration for
the duration of a test, but it wasn't perfect. The new dependency
support mutates the configuration, which can impact other tests.

We're now careful to reset the configuration at the start of each test,
to avoid these sorts of issues. We're also more careful to deep-copy
data into the configuration.

I've also renamed default_config to DEFAULT_CONFIG, to better convey
it's intended as a constant and not something mutable.

Unit tests pass.

This resolved some issues hit with upcoming changes.

Summary ID
Improve some testing and setup around configuration.
Recent changes made it easier to replace the worker configuration for the duration of a test, but it wasn't perfect. The new dependency support mutates the configuration, which can impact other tests. We're now careful to reset the configuration at the start of each test, to avoid these sorts of issues. We're also more careful to deep-copy data into the configuration. I've also renamed `default_config` to `DEFAULT_CONFIG`, to better convey it's intended as a constant and not something mutable.
a2f9d828ca08e862e0b4e8c28c201f79cb63e2a3
david
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-3.0.x (9adc249)
Loading...