test-driven-infrastructure-example icon indicating copy to clipboard operation
test-driven-infrastructure-example copied to clipboard

Rename hello.txt to hello_world.txt

Open philpep opened this issue 9 years ago • 0 comments

This test break because we don't remove the hello.txt resulting to a different state on a full or on a half provisioned system:

Travis build: https://travis-ci.org/philpep/test-driven-infrastructure-example/builds/76951185 Jenkins build: https://jenkins.philpep.org/job/test-driven-infrastructure-example-pr/15/

def test_same_website_root():
        tree = {}
        for name in ("default", "production"):
            conn = testinfra.get_backend(
                name, connection="paramiko", ssh_config=".vagrant-ssh-config")
            Command = conn.get_module("Command")
            tree[name] = Command.check_output("tree /srv/website")

>       assert tree["default"] == tree["production"]
E       assert '/srv/website...ories, 1 file' == '/srv/website\n...ries, 2 files'
E           /srv/website
E         + |-- hello.txt
E           `-- hello_world.txt
E           
E         - 0 directories, 1 file
E         ?                ^
E         + 0 directories, 2 files
E         ?                ^     +

test_same_state.py:12: AssertionError

philpep avatar Aug 21 '15 08:08 philpep