@Test
  public void duplicateStackServiceReposAreCheckedPerOs() throws Exception {
    StackModule sm = createStackModule("FooBar",
        "2.4",
        Optional.absent(),
        Lists.newArrayList(repoInfo("bar", "2.0.1", "http://bar.org", "centos6")),
        Lists.newArrayList(repoInfo("bar", "2.0.1", "http://bar.org", "centos7")));
    Multiset<String> repoIds = getIdsMultiple(sm.getModuleInfo().getRepositories());
    assertEquals("Repo should be occur exactly twice, once for each os type.",
        ImmutableMultiset.of("bar:2.0.1", "bar:2.0.1"), repoIds);
  }
If two add-on services define the same repo, the repo should be disregarded.
This applies per os, so the same repo can be defined for multiple os'es (e.g redhat5 and redhat6)
@throws Exception
ambari-server/src/test/java/org/apache/ambari/server/stack/StackModuleTest.java