testng-team/testng
TestNG tests produce "Static configuration methods can cause unexpected behavior" warnings
Aperta
#2554 aperta il 23 mag 2021
Feature: before/aftergood first issue
Metriche repository
- Star
- (2059 stelle)
- Metriche merge PR
- (Merge medio 17h 43m) (7 PR mergiate in 30 g)
Descrizione
Expected behavior
The test suite should not produce "Static configuration methods can cause unexpected behavior" warnings.
It looks like the tests should be adjusted to avoid unexpected behavior.
Actual behavior
There is a significant number of "Static configuration methods can cause unexpected behavior" warnings in the test suite.
Test case sample
TestNG > Regression2 > test.invokedmethodlistener.InvokedMethodListenerTest > issue87_method_orderning_with_disable_test_class STANDARD_OUT
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.C.someMethod3()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.C.someMethod3()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.A.someMethod1()]. Static configuration methods can cause unexpected behavior.
[Configuration] [WARN] Detected a static method [test.invokedmethodlistener.C.someMethod3()]. Static configuration methods can cause unexpected behavior.