Exemple #1
0
    def test_compile_with_overrides(self):
        actions = [
            ('directory', self.env),
            ('override', 'C=False'),
        ]

        assert compile(actions, {})['C'] == 'False'
Exemple #2
0
    def test_compile_with_overrides(self):
        actions = [
            ('directory', self.env),
            ('override', 'C=False'),
        ]

        assert compile(actions, {})['C'] == 'False'
Exemple #3
0
    def test_compile_with_script_with_pipes(self):
        actions = [
            ('script', 'echo "%s" | xargs cat' % self.env_files[0]),
        ]

        assert compile(actions, {})['A'] == 'True'
Exemple #4
0
    def test_compile_with_script(self):
        actions = [
            ('script', 'cat %s' % self.env_files[0]),
        ]

        assert compile(actions, {})['A'] == 'True'
Exemple #5
0
 def test_compile_with_empty_alias(self):
     actions = [('alias', self.envs_path('empty.yml'))]
     assert compile(actions, {}) == {}
Exemple #6
0
 def test_compile_with_files(self):
     actions = [('file', fname) for fname in self.env_files]
     assert compile(actions, {}) == self.foo_env
Exemple #7
0
 def test_compile_with_alias(self):
     actions = [('alias', os.path.join(HERE, 'envs', 'alias.yml'))]
     assert compile(actions, {}) == self.foo_env
Exemple #8
0
 def test_compile_with_directory(self):
     actions = [('directory', self.env)]
     assert compile(actions, {}) == self.foo_env
Exemple #9
0
    def test_compile_with_script_with_pipes(self):
        actions = [
            ('script', 'echo "%s" | xargs cat' % self.env_files[0]),
        ]

        assert compile(actions, {})['A'] == 'True'
Exemple #10
0
    def test_compile_with_script(self):
        actions = [
            ('script', 'cat %s' % self.env_files[0]),
        ]

        assert compile(actions, {})['A'] == 'True'
Exemple #11
0
 def test_compile_with_empty_alias(self):
     actions = [
         ('alias', self.envs_path('empty.yml'))
     ]
     assert compile(actions, {}) == {}
Exemple #12
0
 def test_compile_with_files(self):
     actions = [
         ('file', fname) for fname in self.env_files
     ]
     assert compile(actions, {}) == self.foo_env
Exemple #13
0
 def test_compile_with_alias(self):
     actions = [('alias', os.path.join(HERE, 'envs', 'alias.yml'))]
     assert compile(actions, {}) == self.foo_env
Exemple #14
0
 def test_compile_with_directory(self):
     actions = [('directory', self.env)]
     assert compile(actions, {}) == self.foo_env