Skip to content

Commit

Permalink
[pkg/stanza/fileconsumer] Decouple test setup code (open-telemetry#12771
Browse files Browse the repository at this point in the history
)

This package has some test utility functions that create a "default"
config that is different than the actual default config. In order for
individual test cases to create their desired configs, they typically
ask for this alternate "default" config and mutate it. The problem is
that setting up a config require reasoning about two layers of defaults,
which is error prone.

This PR simplifies the shared portion of setup code, and pushing a
small amount of very easy setup back into the individual test cases.
This results in clearer tests.
  • Loading branch information
djaglowski committed Jul 29, 2022
1 parent 8f3c623 commit e0450bd
Show file tree
Hide file tree
Showing 4 changed files with 239 additions and 134 deletions.
Loading

0 comments on commit e0450bd

Please sign in to comment.