mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-16 14:23:28 +07:00
22 lines
683 B
HTML
22 lines
683 B
HTML
<html>
|
|
<body>
|
|
Reports calls to <code>assertEquals()</code> that have the expected argument and the actual argument in the wrong order.
|
|
<p>
|
|
For JUnit 3, 4, and 5 the correct order is <code>(expected, actual)</code>.
|
|
For TestNG the correct order is <code>(actual, expected)</code>.
|
|
</p>
|
|
<p>
|
|
Such calls will behave fine for assertions that pass, but may give confusing error reports on failure.
|
|
Use the quick-fix to flip the order of the arguments.
|
|
</p>
|
|
<p><b>Example (JUnit):</b></p>
|
|
<pre><code>
|
|
assertEquals(actual, expected)
|
|
</code></pre>
|
|
<p>After the quick-fix is applied:</p>
|
|
<pre><code>
|
|
assertEquals(expected, actual)
|
|
</code></pre>
|
|
<!-- tooltip end -->
|
|
</body>
|
|
</html> |