Examples of containsAll()


Examples of org.jboss.security.identity.RoleGroup.containsAll()

      sc.getUtil().setRoles(roleGroup);
     
      //Retrieve the roles
      RoleGroup scRoles = sc.getUtil().getRoles();
      assertNotNull(scRoles);
      assertTrue(scRoles.containsAll(new SimpleRole("testRole")));
   }
  
   //Validates JBossSecurityContext is serializable
   public void testJBossSecurityContextSerialization() throws Exception
   {
View Full Code Here

Examples of org.jboss.security.identity.plugins.SimpleRole.containsAll()

      Role firstRole = new SimpleRole("A");
      Role secondRole = new SimpleRole("B");

      assertTrue(firstRole.containsAll(firstRole));
      assertFalse(firstRole.containsAll(secondRole));
      assertFalse(secondRole.containsAll(firstRole));
   }

   public void testSimpleRoleGroupContains() throws Exception
   {
      SimpleRoleGroup firstRoleGroup = new SimpleRoleGroup("firstrg");
View Full Code Here

Examples of org.jboss.security.identity.plugins.SimpleRoleGroup.containsAll()

      SimpleRoleGroup secondRoleGroup = new SimpleRoleGroup("secondrg");
      secondRoleGroup.getRoles().add(new SimpleRole("A"));
      secondRoleGroup.getRoles().add(new SimpleRole("B"));

      assertTrue(firstRoleGroup.containsAll(firstRoleGroup));
      assertTrue(secondRoleGroup.containsAll(secondRoleGroup));
      assertTrue(firstRoleGroup.containsAll(secondRoleGroup));
      assertFalse(secondRoleGroup.containsAll(firstRoleGroup));

      assertTrue(firstRoleGroup.containsAtleastOneRole(secondRoleGroup));
      assertTrue(secondRoleGroup.containsAtleastOneRole(firstRoleGroup));
View Full Code Here

Examples of org.jboss.util.collection.SoftSet.containsAll()

      assertTrue("Key#1000 was removed", set.removeAll(set2));
      assertEquals("Size == 1000", 1000, set.size());
      set.add("Key#1000");
      assertTrue("Key#1000 was removed", set.retainAll(set2));
      assertEquals("Size == 1", 1, set.size());
      assertTrue("set contains [Key#1000]", set.containsAll(set2));
     
      set.clear();
      assertEquals("Size == 0", 0, set.size());
      assertEquals("Size is empty", true, set.isEmpty());
      for(int n = 0; n < 1000; n ++)
View Full Code Here

Examples of org.jboss.weld.test.util.ActionSequence.containsAll()

        bean.destroy(master, ctx);

        ActionSequence init = ActionSequence.getSequence("init");
        assertNotNull(init);
        assertEquals(2, init.getData().size());
        assertTrue(init.containsAll(Alpha.class.getName(), Bravo.class.getName()));

        ActionSequence destroy = ActionSequence.getSequence("destroy");
        assertNotNull(destroy);
        assertEquals(2, destroy.getData().size());
        assertTrue(destroy.containsAll(Alpha.class.getName(), Bravo.class.getName()));
View Full Code Here

Examples of org.jgroups.util.MutableDigest.containsAll()

    public void testContainsAll() {
        MutableDigest digest=new MutableDigest(members);
        digest.set(a1,1,1);
        digest.set(a2,1,1);
        assert digest.containsAll(a1, a2, a3);
        digest.set(a3,1,1);
        assert digest.containsAll(a1, a2, a3);
        assert d.containsAll(a1, a2, a3);
    }
View Full Code Here

Examples of org.json.simple.JSONArray.containsAll()

      assertEquals(alertKey, alert.get("loc-key"));

      final JSONArray argsArray = (JSONArray) alert.get("loc-args");
      assertEquals(alertArgs.length, argsArray.size());
      assertTrue(argsArray.containsAll(java.util.Arrays.asList(alertArgs)));
    }
  }

  @Test(expected = IllegalStateException.class)
  public void testSetAlertBodyWithExistingLocalizedAlert() {
View Full Code Here

Examples of org.kitesdk.data.spi.CharSequences.ImmutableCharSequenceSet.containsAll()

    for (String color : colors) {
      Assert.assertTrue("Should contain Utf8(value)",
          set.contains(new Utf8(color)));
    }
    Assert.assertTrue("Should contain all values",
        set.containsAll(colors));
  }

  @Test
  public void testUtf8CharSequenceSetContains() {
    List<Utf8> colors = Lists.newArrayList(
View Full Code Here

Examples of org.mcarthur.sandy.gwt.event.list.client.EventList.containsAll()

        el.addAll(l);

        Collections.shuffle(l, new Random(4372));

        assertTrue(l.containsAll(el));
        assertTrue(el.containsAll(l));

        final List sub = new ArrayList(l.subList(50, 100));

        l.removeAll(sub);
        el.removeAll(sub);
View Full Code Here

Examples of org.mcarthur.sandy.gwt.event.list.client.FilteredEventList.containsAll()

        assertEquals(10, el.size());
        assertEquals(5, fel.size());
        assertEquals(5, sel.size());
        assertTrue(el.containsAll(fel));
        assertTrue(el.containsAll(sel));
        assertTrue(fel.containsAll(sel));
        assertTrue(sel.containsAll(fel));

        final List sorted = new ArrayList(sel);
        Collections.sort(sorted);
        assertEquals(sorted, sel);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.