Example #1
0
 def test_jagged_alliance(self):
     os.chdir('tests/files/bat/jagged-alliance')
     self.assertTrue(toolbox.is_trivial_batch('run.bat'))
     path, args = toolbox.read_trivial_batch('run.bat')
     self.assertIsNone(path)
     self.assertEqual(args, [
         '-c', 'MOUNT c Installed', '-c', 'IMGMOUNT d cd.iso -t cdrom',
         '-c', 'c:', '-c', 'cd jagged', '-c', 'ja.bat', '-c', 'exit'
     ])
Example #2
0
 def test_worms(self):
     os.chdir('tests/files/bat/worms')
     self.assertTrue(toolbox.is_trivial_batch('runworms.bat'))
     path, args = toolbox.read_trivial_batch('runworms.bat')
     self.assertIsNone(path)
     self.assertEqual(args, [
         r'.\drivec\goworms.bat', '-conf', r'.\worms.conf', '-fullscreen',
         '-exit'
     ])
Example #3
0
 def disabled_test_larry7_2(self):
     os.chdir('tests/files/bat')
     self.assertTrue(toolbox.is_trivial_batch('larry7/run.bat'))
     path, args = toolbox.read_trivial_batch('larry7/run.bat')
     self.assertEqual(path, 'larry7/DOSBOX')
     self.assertEqual(args, ['-conf', r'..\lsl7.conf', '-c', 'exit'])
Example #4
0
 def test_stargunner(self):
     os.chdir('tests/files/bat/stargunner')
     self.assertFalse(toolbox.is_trivial_batch('Stargunner.bat'))
Example #5
0
 def test_doom2_2(self):
     os.chdir('tests/files/bat/doom2')
     self.assertTrue(toolbox.is_trivial_batch('doom2 + mouse.bat'))
Example #6
0
 def test_different_extension(self):
     os.chdir('tests/files/no_conf')
     self.assertFalse(toolbox.is_trivial_batch('file.exe'))
Example #7
0
 def test_missing_file(self):
     os.chdir('tests/files/bat/doom2')
     self.assertFalse(toolbox.is_trivial_batch('I_do_not_exist.bat'))