def test_children3(self):
        th = TestHelper()
        # add a top level prefix
        p1 = th.add_prefix('1.0.0.0/24', 'assignment', 'test')

        # check stats for p1
        res = Prefix.smart_search('1.0.0.0/24', {})
        self.assertEqual(0, res['result'][0].children)

        # add a covering supernet around p1
        p2 = th.add_prefix('1.0.0.0/20', 'reservation', 'bar')

        # check stats for p2, our new top level prefix
        res = Prefix.smart_search('1.0.0.0/20', {})
        self.assertEqual(1, res['result'][0].children)
Check children are correct when adding prefix
dataset/ETHPy150Open SpriteLink/NIPAP/tests/nipaptest.py/TestPrefixChildren.test_children3