(self)
| 1776 | MRNullSpark, [])) |
| 1777 | |
| 1778 | def test_basic_setup(self): |
| 1779 | content = self._get_python_wrapper_content( |
| 1780 | MRNullSpark, ['--setup', 'echo blarg']) |
| 1781 | self.assertIsNotNone(content) |
| 1782 | |
| 1783 | # should have shebang |
| 1784 | first_line = content.split('\n')[0] |
| 1785 | self.assertEqual(first_line, ('#!/bin/sh -ex')) |
| 1786 | self.assertFalse(self.log.warning.called) |
| 1787 | |
| 1788 | # should contain command |
| 1789 | self.assertIn('echo blarg', content) |
| 1790 | |
| 1791 | # should wrap python |
| 1792 | self.assertIn('%s "$@"' % PYTHON_BIN, content) |
| 1793 | |
| 1794 | def test_env_shebang(self): |
| 1795 | content = self._get_python_wrapper_content( |
nothing calls this directly
no test coverage detected