aboutsummaryrefslogtreecommitdiffstats
path: root/bundle-plugin-test
diff options
context:
space:
mode:
authorgjoranv <gv@oath.com>2018-09-13 16:11:29 +0200
committergjoranv <gv@oath.com>2018-09-13 16:15:12 +0200
commit8f4ed7fef4f036db944161d9fb9ec29b9a5dacab (patch)
tree120333b83fce8255bfd622e1ffd5ce9701549313 /bundle-plugin-test
parent76f4a719f366a8f804d3748f275b31f2842b3479 (diff)
Enable and fix test to verify bundle version.
- Due to snapshot builds we can only verify the major version.
Diffstat (limited to 'bundle-plugin-test')
-rw-r--r--bundle-plugin-test/src/test/java/com/yahoo/BundleIT.java10
1 files changed, 7 insertions, 3 deletions
diff --git a/bundle-plugin-test/src/test/java/com/yahoo/BundleIT.java b/bundle-plugin-test/src/test/java/com/yahoo/BundleIT.java
index ccee4844b49..38ca08ecff1 100644
--- a/bundle-plugin-test/src/test/java/com/yahoo/BundleIT.java
+++ b/bundle-plugin-test/src/test/java/com/yahoo/BundleIT.java
@@ -2,6 +2,7 @@
package com.yahoo;
import com.yahoo.osgi.maven.ProjectBundleClassPaths;
+import com.yahoo.vespa.config.VespaVersion;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
@@ -64,9 +65,12 @@ public class BundleIT {
}
@Test
- @Ignore // TODO Vespa 7: Should we fix this? Why not?
- public void require_that_bundle_version_matches_pom_version() {
- assertThat(mainAttributes.getValue("Bundle-Version"), is("5.1.0"));
+ public void require_that_bundle_version_is_added_to_manifest() {
+ String bundleVersion = mainAttributes.getValue("Bundle-Version");
+
+ // Because of snapshot builds, we can only verify the major version.
+ int majorBundleVersion = Integer.valueOf(bundleVersion.substring(0, bundleVersion.indexOf('.')));
+ assertThat(majorBundleVersion, is(VespaVersion.major));
}
@Test