Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(62)  |  Call(62)  |  Derive(0)  |  Import(0)

src/e/o/Eos-HEAD/tests/cache_generator/checks/test_rack_collision.py   Eos(Download)
    def test_collision(self):
        data = self.run_generator()
        self.assertEqual(len(self.log), 2)
        clean_stats = self.log[0]
        self.assertEqual(clean_stats.name, 'eos_test.cache_generator')
    def test_cleaned(self):
        del self.item['groupID']
        data = self.run_generator()
        self.assertEqual(len(self.log), 1)
        clean_stats = self.log[0]

src/e/o/Eos-HEAD/tests/cache_generator/checks/test_default_effects.py   Eos(Download)
    def test_normal(self):
        self.eff_link1['isDefault'] = False
        self.eff_link2['isDefault'] = True
        data = self.run_generator()
        self.assertEqual(len(self.log), 1)
    def test_duplicate(self):
        self.eff_link1['isDefault'] = True
        self.eff_link2['isDefault'] = True
        data = self.run_generator()
        self.assertEqual(len(self.log), 2)
    def test_cleanup(self):
        del self.item['groupID']
        self.eff_link1['isDefault'] = True
        self.eff_link2['isDefault'] = True
        data = self.run_generator()

src/e/o/Eos-HEAD/tests/cache_generator/checks/test_attr_value.py   Eos(Download)
    def test_int(self):
        self.dh.data['invtypes'].append({'typeID': 1, 'groupID': 1, 'typeName': ''})
        self.dh.data['dgmtypeattribs'].append({'typeID': 1, 'attributeID': 5, 'value': 8})
        data = self.run_generator()
        self.assertEqual(len(self.log), 1)
    def test_float(self):
        self.dh.data['invtypes'].append({'typeID': 1, 'groupID': 1, 'typeName': ''})
        self.dh.data['dgmtypeattribs'].append({'typeID': 1, 'attributeID': 5, 'value': 8.5})
        data = self.run_generator()
        self.assertEqual(len(self.log), 1)
    def test_other(self):
        self.dh.data['invtypes'].append({'typeID': 1, 'groupID': 1, 'typeName': ''})
        self.dh.data['dgmtypeattribs'].append({'typeID': 1, 'attributeID': 5, 'value': None})
        data = self.run_generator()
        self.assertEqual(len(self.log), 2)
    def test_cleanup(self):
        # Make sure cleanup runs before check being tested
        self.dh.data['invtypes'].append({'typeID': 1, 'typeName': ''})
        self.dh.data['dgmtypeattribs'].append({'typeID': 1, 'attributeID': 5, 'value': None})
        data = self.run_generator()

Previous  1 | 2