예제 #1
0
 def test_render_groups(self):
     # ensure that a given rule set is converted to the equivalent security
     # group hierachy
     rs = RuleSet()
     for flat in self.flat:
         rs.add(Rule(flat))
     self.assertEqual(self.groups, rs.render_groups())
예제 #2
0
 def test_render_groups(self):
     # ensure that a given rule set is converted to the equivalent security
     # group hierachy
     rs = RuleSet()
     for flat in self.flat:
         rs.add(Rule(flat))
     self.assertEqual(self.groups, rs.render_groups())
예제 #3
0
 def test_add_rule(self):
     # ensure that rules are coerced to Rules
     rs = RuleSet()
     rs.add(dict(chain(self.rule_params.items(), self.cidrsrc_param.items())))
     self.assertIsInstance(rs.pop(), Rule)
예제 #4
0
 def test_add_rule(self):
     # ensure that rules are coerced to Rules
     rs = RuleSet()
     rs.add(
         dict(chain(self.rule_params.items(), self.cidrsrc_param.items())))
     self.assertIsInstance(rs.pop(), Rule)