aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-testing-harness/src/main/java/org/sonar/test/i18n
diff options
context:
space:
mode:
authorFabrice Bellingard <fabrice.bellingard@sonarsource.com>2012-10-03 12:32:09 +0200
committerFabrice Bellingard <fabrice.bellingard@sonarsource.com>2012-10-03 12:33:22 +0200
commitc024588873d4b1b235b70371ec897b97d6e25fdb (patch)
treeedf6eb8943a01f100be595fe75683791ae35e6be /sonar-testing-harness/src/main/java/org/sonar/test/i18n
parent62ec1ada6f9c17f4e20fc1905a1c98d67461be78 (diff)
downloadsonarqube-c024588873d4b1b235b70371ec897b97d6e25fdb.tar.gz
sonarqube-c024588873d4b1b235b70371ec897b97d6e25fdb.zip
SONAR-3736 Fix regression (additional keys not displayed if any)
Diffstat (limited to 'sonar-testing-harness/src/main/java/org/sonar/test/i18n')
-rw-r--r--sonar-testing-harness/src/main/java/org/sonar/test/i18n/BundleSynchronizedMatcher.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/sonar-testing-harness/src/main/java/org/sonar/test/i18n/BundleSynchronizedMatcher.java b/sonar-testing-harness/src/main/java/org/sonar/test/i18n/BundleSynchronizedMatcher.java
index ca49bcec1de..4ccd121179c 100644
--- a/sonar-testing-harness/src/main/java/org/sonar/test/i18n/BundleSynchronizedMatcher.java
+++ b/sonar-testing-harness/src/main/java/org/sonar/test/i18n/BundleSynchronizedMatcher.java
@@ -60,8 +60,15 @@ public class BundleSynchronizedMatcher extends BaseMatcher<String> {
// and now let's compare!
try {
+ // search for missing keys
missingKeys = retrieveMissingTranslations(bundleInputStream, defaultBundleInputStream);
+
+ // and now for additional keys
+ bundleInputStream = getBundleFileInputStream(bundleName);
+ defaultBundleInputStream = getDefaultBundleFileInputStream(bundleName);
additionalKeys = retrieveMissingTranslations(defaultBundleInputStream, bundleInputStream);
+
+ // And fail only if there are missing keys
return missingKeys.isEmpty();
} catch (IOException e) {
fail("An error occured while reading the bundles: " + e.getMessage());