You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Having test projects that are specific to a particular logging system and test all DI framework adapters (e.g., loginject-test-log4j) is a problematic approach for a number of reasons. For example, Dagger and Dagger 2 use the same package name, so it is not possible to have both DI frameworks on the classpath at the same time. Also, in the DI-specific tests that are part of each DI adapter, there is a considerable amount of code duplication for setting up the test scenarios.
Ideas:
Have a common project as a test dependency that contains all test scenarios (without bindings)
Each DI adapter provides bindings for the test scenario
Maybe introduce an abstraction to the various instantiation APIs, so that shared tests can be run for each DI adapter, provided that there is a binding and an instantiation adapter implementation
The shared test scenario project could depend on all tested logging frameworks
Utilize JUnit parameterized testing to support Cartesian product of (all DI adapters) x (all logging frameworks)
The text was updated successfully, but these errors were encountered:
Having test projects that are specific to a particular logging system and test all DI framework adapters (e.g., loginject-test-log4j) is a problematic approach for a number of reasons. For example, Dagger and Dagger 2 use the same package name, so it is not possible to have both DI frameworks on the classpath at the same time. Also, in the DI-specific tests that are part of each DI adapter, there is a considerable amount of code duplication for setting up the test scenarios.
Ideas:
The text was updated successfully, but these errors were encountered: