Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMykola Nikishov2018-07-23 09:57:53 +0000
committerAlexander Kurtakov2018-10-03 06:31:33 +0000
commit909347bbf63f88048fa277ef72ced50de579c555 (patch)
tree65bde4d73f88489dc458a63df6b8f85087494424
parent81be2eb2f2ed2194ecaa866ad221a4af5a093425 (diff)
downloadrt.equinox.p2-909347bbf63f88048fa277ef72ced50de579c555.tar.gz
rt.equinox.p2-909347bbf63f88048fa277ef72ced50de579c555.tar.xz
rt.equinox.p2-909347bbf63f88048fa277ef72ced50de579c555.zip
Bug 536326 - Improve messages in MirrorRequestTest's testFailToCanonical
Message junit.framework.AssertionFailedError: Exact number of downloads expected:<12> but was:<2> is more specific than original one: junit.framework.AssertionFailedError: Number of downloads differs from expected attempts. Also print artifact's key. Change-Id: Idcebd80c9b94161d895e1ba56b50f90518630b16 Signed-off-by: Mykola Nikishov <mn@mn.com.ua>
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/MirrorRequestTest.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/MirrorRequestTest.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/MirrorRequestTest.java
index b82e77c60..c55ef645c 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/MirrorRequestTest.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/MirrorRequestTest.java
@@ -100,8 +100,8 @@ public class MirrorRequestTest extends AbstractProvisioningTest {
request.perform(src, new NullProgressMonitor());
assertTrue(request.getResult().toString(), request.getResult().isOK());
- assertTrue("Target does not contain artifact.", targetRepository.contains(key));
- assertTrue("Number of downloads differs from expected attempts.", src.downloadCount == 2);
+ assertTrue(String.format("Target does not contain artifact %s", key), targetRepository.contains(key));
+ assertEquals("Exact number of downloads", 2, src.downloadCount);
}
// Test that SimpleArtifactRepository & MirrorRequest use mirrors in the event of a failure.

Back to the top