Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New image structure based on design document #166

Merged
merged 21 commits into from
Sep 28, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add test to check that apt-get didn't remove any package
  • Loading branch information
humitos committed Sep 2, 2021
commit 0137a5814e4e9b12df00556c11d807c73aeb78d4
1 change: 1 addition & 0 deletions tests/constants.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DOCKER_IMAGE = 'readthedocs/build:ubuntu20'
13 changes: 13 additions & 0 deletions tests/test_apt.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import pytest

from .constants import DOCKER_IMAGE
from .utils import run_command_in_container



def test_apt_dont_remove_packages():
command ='grep "Remove:" /var/log/apt/history.log'
expected_output = ''

cmd_output = run_command_in_container(DOCKER_IMAGE, command)
assert cmd_output == expected_output
4 changes: 2 additions & 2 deletions tests/test_versions.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest
from docker import APIClient

from .constants import DOCKER_IMAGE
from .utils import run_command_in_container


Expand All @@ -13,5 +13,5 @@
]
)
def test_command_versions_image_ubuntu20(command, expected_output):
cmd_output = run_command_in_container('readthedocs/build:ubuntu20', command)
cmd_output = run_command_in_container(DOCKER_IMAGE, command)
assert cmd_output == expected_output