Пример #1
0
 def test_absent(self):
     with io.open(self.test_file, "w", encoding='utf-8') as f:
         f.write(resources.unicode_desktop)
     
     entry = DesktopEntry(self.test_file)
     res = entry.findTryExec()
     assert res is None, repr(res)
Пример #2
0
    def test_absent(self):
        with io.open(self.test_file, "w", encoding='utf-8') as f:
            f.write(resources.unicode_desktop)

        entry = DesktopEntry(self.test_file)
        res = entry.findTryExec()
        assert res is None, repr(res)
Пример #3
0
 def test_present(self):
     with io.open(self.test_file, "w", encoding='utf-8') as f:
         f.write(resources.python_desktop)
     
     entry = DesktopEntry(self.test_file)
     res = entry.findTryExec()
     assert res, repr(res)
Пример #4
0
    def test_present(self):
        with io.open(self.test_file, "w", encoding='utf-8') as f:
            f.write(resources.python_desktop)

        entry = DesktopEntry(self.test_file)
        res = entry.findTryExec()
        assert res, repr(res)