Test Setup Failed
Push — master ( 4c7575...8ed87e )
by Jace
01:18
created

describe_cli()   A

Complexity

Conditions 3

Size

Total Lines 9

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
cc 3
c 2
b 0
f 0
dl 0
loc 9
rs 9.6666

2 Methods

Rating   Name   Duplication   Size   Complexity  
A describe_init() 0 7 2
A when_config_missing() 0 5 1
1
# pylint: disable=redefined-outer-name,unused-variable,expression-not-assigned,singleton-comparison
2
3
import pytest
4
from expecter import expect
5
6
from click.testing import CliRunner
7
8
from envdiff.cli import main
9
10
11
@pytest.fixture
12
def runner():
13
    return CliRunner()
14
15
16
def describe_cli():
17
18
    def describe_init():
19
20
        def when_config_missing(runner):
21
            result = runner.invoke(main, ['--init'])
22
23
            expect(result.exit_code) == 0
24
            expect(result.output) == "Created env-diff.yml\n"
25