Skip to content

Fix parameter order in assertEquals#2066

Merged
eddumelendez merged 3 commits intodocker-java:masterfrom
albers:fix-assert-equals-parameter-order
Feb 9, 2023
Merged

Fix parameter order in assertEquals#2066
eddumelendez merged 3 commits intodocker-java:masterfrom
albers:fix-assert-equals-parameter-order

Conversation

@albers
Copy link
Copy Markdown
Contributor

@albers albers commented Feb 9, 2023

Fixes #1923

Parameter order

Docker-Java used to implement its tests with TestNG until #909.
In TestNG, assertEquals has a different parameter order (actual, expected) compared to JUnit (expected, actual).

Some old tests still use the old parameter ordering, some tests follow the JUnit semantics.
There are even test classes which mix both forms.

While this does not affect the validity of the tests, it confuses the reader and therefore should be cleaned up.

Housekeeping

Being at it, I did some basic housekeeping on the tests: I removed some unused imports and unneccessary throws declarations.

@eddumelendez eddumelendez added this to the next milestone Feb 9, 2023
@eddumelendez eddumelendez merged commit 26cd13c into docker-java:master Feb 9, 2023
@eddumelendez
Copy link
Copy Markdown
Member

Thanks for your contribution, @albers ! This is now merged in master branch.

@albers
Copy link
Copy Markdown
Contributor Author

albers commented Feb 9, 2023

Thanks for the quick review and merge.

@albers albers deleted the fix-assert-equals-parameter-order branch February 9, 2023 22:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Test Smell: the wrong parameter order in ''assertEquals'' assertion

2 participants