def test_init(self): sorter = SpecifierSorter() self.assertIsNone(sorter.category_for_specifier('control')) sorter = SpecifierSorter(self._all_test_configurations) self.assertEqual(sorter.category_for_specifier('win7'), 'version') sorter = SpecifierSorter(self._all_test_configurations, MOCK_MACROS) self.assertEqual(sorter.category_for_specifier('mac'), 'version')
def test_init(self): sorter = SpecifierSorter() self.assertIsNone(sorter.category_for_specifier("control")) sorter = SpecifierSorter(self._all_test_configurations) self.assertEqual(sorter.category_for_specifier("win7"), "version") sorter = SpecifierSorter(self._all_test_configurations, MOCK_MACROS) self.assertEqual(sorter.category_for_specifier("mac"), "version")
def test_init(self): sorter = SpecifierSorter() self.assertIsNone(sorter.category_for_specifier('control')) sorter = SpecifierSorter(self._all_test_configurations) self.assertEqual(sorter.category_for_specifier('win7'), 'version') sorter = SpecifierSorter(self._all_test_configurations, MOCK_MACROS) self.assertEqual(sorter.category_for_specifier('mac'), 'version')
def test_add_specifier(self): sorter = SpecifierSorter() self.assertIsNone(sorter.category_for_specifier("control")) sorter.add_specifier("version", "control") self.assertEqual(sorter.category_for_specifier("control"), "version") sorter.add_specifier("version", "one") self.assertEqual(sorter.category_for_specifier("one"), "version") sorter.add_specifier("architecture", "renaissance") self.assertEqual(sorter.category_for_specifier("one"), "version") self.assertEqual(sorter.category_for_specifier("renaissance"), "architecture")
def test_add_specifier(self): sorter = SpecifierSorter() self.assertIsNone(sorter.category_for_specifier('control')) sorter.add_specifier('version', 'control') self.assertEqual(sorter.category_for_specifier('control'), 'version') sorter.add_specifier('version', 'one') self.assertEqual(sorter.category_for_specifier('one'), 'version') sorter.add_specifier('architecture', 'renaissance') self.assertEqual(sorter.category_for_specifier('one'), 'version') self.assertEqual(sorter.category_for_specifier('renaissance'), 'architecture')
def test_add_specifier(self): sorter = SpecifierSorter() self.assertIsNone(sorter.category_for_specifier('control')) sorter.add_specifier('version', 'control') self.assertEqual(sorter.category_for_specifier('control'), 'version') sorter.add_specifier('version', 'one') self.assertEqual(sorter.category_for_specifier('one'), 'version') sorter.add_specifier('architecture', 'renaissance') self.assertEqual(sorter.category_for_specifier('one'), 'version') self.assertEqual(sorter.category_for_specifier('renaissance'), 'architecture')
def test_add_macros(self): sorter = SpecifierSorter(self._all_test_configurations) sorter.add_macros(MOCK_MACROS) self.assertEqual(sorter.category_for_specifier("mac"), "version") self.assertEqual(sorter.category_for_specifier("win"), "version") self.assertEqual(sorter.category_for_specifier("x86"), "architecture")
def test_add_macros(self): sorter = SpecifierSorter(self._all_test_configurations) sorter.add_macros(MOCK_MACROS) self.assertEqual(sorter.category_for_specifier('mac'), 'version') self.assertEqual(sorter.category_for_specifier('win'), 'version') self.assertEqual(sorter.category_for_specifier('x86'), 'architecture')
def test_add_macros(self): sorter = SpecifierSorter(self._all_test_configurations) sorter.add_macros(MOCK_MACROS) self.assertEqual(sorter.category_for_specifier('mac'), 'version') self.assertEqual(sorter.category_for_specifier('win'), 'version') self.assertEqual(sorter.category_for_specifier('x86'), 'architecture')