301782ae18
* Use pytest-cs 0.2 * fix pipenv cache key * Cache docker layers * Load build images from buildx to docker * CI: commit Pipfile.lock * Add full docker tag * Cache only amd64 docker layers * Cache layer mode=min
17 lines
473 B
Python
17 lines
473 B
Python
#!/usr/bin/env python
|
|
|
|
import pytest
|
|
|
|
pytestmark = pytest.mark.docker
|
|
|
|
|
|
# XXX this is redundant, already tested in pytest_cs
|
|
def test_crowdsec(crowdsec):
|
|
with crowdsec() as cs:
|
|
for waiter in cs.log_waiters():
|
|
with waiter as matcher:
|
|
matcher.fnmatch_lines(["*Starting processing data*"])
|
|
res = cs.cont.exec_run('sh -c "echo $CI_TESTING"')
|
|
assert res.exit_code == 0
|
|
assert 'true' == res.output.decode().strip()
|