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
await().atMost(timeout).untilAsserted(() -> assertThatThrownBy(() -> CONSUMER.pullData(edr, Map.of("message", msg), body -> assertThat(body).isEqualTo("data"))));
This duplication is likely to increase as new tests are added, making the codebase harder to maintain and understand.
Solution Proposal
If possible, provide a (brief!) solution proposal.
Create private methods to handle the duplicated code, reuse them across tests, and establish a clearer structure. This approach will make the code more readable, maintainable, and compact.
The text was updated successfully, but these errors were encountered:
Feature Request
Refactor End-to-End (e2e) PULL Transfer Tests to avoid code duplication
Which Areas Would Be Affected?
TransferPullEndToEndTest
classWhy Is the Feature Desired?
There is significant code duplication, especially in the following tests:
httpPull_dataTransfer_withEdrCache
suspendAndResumeByConsumer_httpPull_dataTransfer_withEdrCache
suspendAndResumeByProvider_httpPull_dataTransfer_withEdrCache
pullFromHttp_httpProvision
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 149 to 153 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 175 to 179 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 211 to 215 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 259 to 263 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 293 to 295 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 308 to 310 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 155 to 159 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 181 to 184 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 199 to 201 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 217 to 220 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 239 to 241 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 265 to 268 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 161 to 165 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 190 to 193 in 7eb2ef7
Connector/system-tests/e2e-transfer-test/runner/src/test/java/org/eclipse/edc/test/e2e/TransferPullEndToEndTest.java
Lines 230 to 233 in 7eb2ef7
This duplication is likely to increase as new tests are added, making the codebase harder to maintain and understand.
Solution Proposal
If possible, provide a (brief!) solution proposal.
Create private methods to handle the duplicated code, reuse them across tests, and establish a clearer structure. This approach will make the code more readable, maintainable, and compact.
The text was updated successfully, but these errors were encountered: