Пример #1
0
class ImportantManagerTestCase(unittest.TestCase):
    def setUp(self):
        self.i = ImportantManager(["a", "b*", "Readme.md"])

    def assertImportant(self, files):
        self.assertTrue(self.i.fileIsImportant(fakeChange(files)))

    def assertNotImportant(self, files):
        self.assertFalse(self.i.fileIsImportant(fakeChange(files)))

    def test_AllImportant(self):
        self.i = ImportantManager([])
        self.assertImportant(["file.c"])

    def test_basic(self):
        self.assertImportant(["file.c"])

    def test_basic2(self):
        self.assertNotImportant(["Readme.md"])

    def test_basic3(self):
        self.assertNotImportant(["a", "basic", "Readme.md"])

    def test_basic4(self):
        self.assertImportant(["a", "basic", "Readme.md", "file.c"])
Пример #2
0
class ImportantManagerTestCase(unittest.TestCase):

    def setUp(self):
        self.i = ImportantManager(["a", "b*", "Readme.md"])

    def assertImportant(self, files):
        self.assertTrue(self.i.fileIsImportant(fakeChange(files)))

    def assertNotImportant(self, files):
        self.assertFalse(self.i.fileIsImportant(fakeChange(files)))

    def test_AllImportant(self):
        self.i = ImportantManager([])
        self.assertImportant(["file.c"])

    def test_basic(self):
        self.assertImportant(["file.c"])

    def test_basic2(self):
        self.assertNotImportant(["Readme.md"])

    def test_basic3(self):
        self.assertNotImportant(["a", "basic", "Readme.md"])

    def test_basic4(self):
        self.assertImportant(["a", "basic", "Readme.md", "file.c"])
Пример #3
0
 def test_AllImportant(self):
     self.i = ImportantManager([])
     self.assertImportant(["file.c"])
Пример #4
0
 def setUp(self):
     self.i = ImportantManager(["a", "b*", "Readme.md"])
Пример #5
0
 def test_AllImportant(self):
     self.i = ImportantManager([])
     self.assertImportant(["file.c"])
Пример #6
0
 def setUp(self):
     self.i = ImportantManager(["a", "b*", "Readme.md"])