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

        assert compile(actions, {})['C'] == 'False'
コード例 #2
0
ファイル: test_env.py プロジェクト: ionrock/withenv
    def test_compile_with_overrides(self):
        actions = [
            ('directory', self.env),
            ('override', 'C=False'),
        ]

        assert compile(actions, {})['C'] == 'False'
コード例 #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'
コード例 #4
0
    def test_compile_with_script(self):
        actions = [
            ('script', 'cat %s' % self.env_files[0]),
        ]

        assert compile(actions, {})['A'] == 'True'
コード例 #5
0
 def test_compile_with_empty_alias(self):
     actions = [('alias', self.envs_path('empty.yml'))]
     assert compile(actions, {}) == {}
コード例 #6
0
 def test_compile_with_files(self):
     actions = [('file', fname) for fname in self.env_files]
     assert compile(actions, {}) == self.foo_env
コード例 #7
0
 def test_compile_with_alias(self):
     actions = [('alias', os.path.join(HERE, 'envs', 'alias.yml'))]
     assert compile(actions, {}) == self.foo_env
コード例 #8
0
 def test_compile_with_directory(self):
     actions = [('directory', self.env)]
     assert compile(actions, {}) == self.foo_env
コード例 #9
0
ファイル: test_env.py プロジェクト: ionrock/withenv
    def test_compile_with_script_with_pipes(self):
        actions = [
            ('script', 'echo "%s" | xargs cat' % self.env_files[0]),
        ]

        assert compile(actions, {})['A'] == 'True'
コード例 #10
0
ファイル: test_env.py プロジェクト: ionrock/withenv
    def test_compile_with_script(self):
        actions = [
            ('script', 'cat %s' % self.env_files[0]),
        ]

        assert compile(actions, {})['A'] == 'True'
コード例 #11
0
ファイル: test_env.py プロジェクト: ionrock/withenv
 def test_compile_with_empty_alias(self):
     actions = [
         ('alias', self.envs_path('empty.yml'))
     ]
     assert compile(actions, {}) == {}
コード例 #12
0
ファイル: test_env.py プロジェクト: ionrock/withenv
 def test_compile_with_files(self):
     actions = [
         ('file', fname) for fname in self.env_files
     ]
     assert compile(actions, {}) == self.foo_env
コード例 #13
0
ファイル: test_env.py プロジェクト: ionrock/withenv
 def test_compile_with_alias(self):
     actions = [('alias', os.path.join(HERE, 'envs', 'alias.yml'))]
     assert compile(actions, {}) == self.foo_env
コード例 #14
0
ファイル: test_env.py プロジェクト: ionrock/withenv
 def test_compile_with_directory(self):
     actions = [('directory', self.env)]
     assert compile(actions, {}) == self.foo_env