Beispiel #1
0
    def test_class_with_base_finds_same_errors(self):
        failures_with_classes_with_base, _ = apilint.examine_stream(
            "",
            faulty_current_txt,
            in_classes_with_base=[cls("android.app", "WallpaperColors")])
        failures_with_system_txt, _ = apilint.examine_stream(
            system_current_txt, faulty_current_txt)

        self.assertEquals(failures_with_classes_with_base.keys(),
                          failures_with_system_txt.keys())
Beispiel #2
0
 def test_classes_with_base_is_emited(self):
     classes_with_base = []
     _, _ = apilint.examine_stream(system_current_txt,
                                   faulty_current_txt,
                                   out_classes_with_base=classes_with_base)
     self.assertEquals(map(lambda x: x.fullname, classes_with_base),
                       ["android.app.WallpaperColors"])
Beispiel #3
0
 def test_base_file_avoids_errors(self):
     failures, _ = apilint.examine_stream(system_current_txt,
                                          ok_current_txt)
     self.assertEquals(failures, {})