diff options
author | Ben Sturmfels <ben@sturm.com.au> | 2021-03-09 16:56:28 +1100 |
---|---|---|
committer | Ben Sturmfels <ben@sturm.com.au> | 2021-03-09 16:56:28 +1100 |
commit | 3ba11716c10d285f0373c2dfc3650c0af453896b (patch) | |
tree | 2c736b3e33a52540221526987cd326f267deb6aa | |
parent | 95be20a936e703903b1797bf109547c01019cd1d (diff) | |
download | mediagoblin-3ba11716c10d285f0373c2dfc3650c0af453896b.tar.lz mediagoblin-3ba11716c10d285f0373c2dfc3650c0af453896b.tar.xz mediagoblin-3ba11716c10d285f0373c2dfc3650c0af453896b.zip |
Run LDAP, OpenID and PDF tests under Docker.
-rw-r--r-- | .builds/debian-10-with-site-packages.yml | 8 | ||||
-rw-r--r-- | .builds/fedora-33-with-site-packages.yml | 6 | ||||
-rw-r--r-- | Dockerfile-debian-python3-sqlite | 9 | ||||
-rw-r--r-- | Dockerfile-fedora-python3-sqlite | 14 | ||||
-rw-r--r-- | mediagoblin/plugins/openid/README.rst | 2 | ||||
-rw-r--r--[l---------] | mediagoblin/tests/test_submission/good.pdf | bin | 44 -> 8899 bytes |
6 files changed, 34 insertions, 5 deletions
diff --git a/.builds/debian-10-with-site-packages.yml b/.builds/debian-10-with-site-packages.yml index 8b8760a7..1f672a6b 100644 --- a/.builds/debian-10-with-site-packages.yml +++ b/.builds/debian-10-with-site-packages.yml @@ -43,7 +43,13 @@ packages: # Install document (PDF-only) dependencies. - poppler-utils - + + # Install LDAP depedencies. + - python3-ldap + + # Install OpenID dependencies. + - python3-openid + tasks: - core: | cd mediagoblin diff --git a/.builds/fedora-33-with-site-packages.yml b/.builds/fedora-33-with-site-packages.yml index 562441fd..0a0fce34 100644 --- a/.builds/fedora-33-with-site-packages.yml +++ b/.builds/fedora-33-with-site-packages.yml @@ -45,6 +45,12 @@ packages: # # Install document (PDF-only) dependencies. # - poppler-utils + + # Install LDAP depedencies. + - python3-ldap + + # Install OpenID dependencies. + - python3-openid tasks: - core: | diff --git a/Dockerfile-debian-python3-sqlite b/Dockerfile-debian-python3-sqlite index 8f38879c..bf22b9cf 100644 --- a/Dockerfile-debian-python3-sqlite +++ b/Dockerfile-debian-python3-sqlite @@ -112,6 +112,12 @@ libboost-python-dev RUN apt-get install -y \ poppler-utils +# Install LDAP depedencies. +RUN apt-get install -y python3-ldap + +# Install OpenID dependencies. +RUN apt-get install -y python3-openid + # Create working directory. RUN mkdir /opt/mediagoblin RUN chown -R www-data:www-data /opt/mediagoblin @@ -167,7 +173,8 @@ RUN make RUN ./bin/pip install py3exiv2 # Run the tests. -RUN ./bin/python -m pytest ./mediagoblin/tests --boxed +RUN echo foo +RUN ./bin/python -m pytest -rs ./mediagoblin/tests --boxed # Only safe if being run on a clean git checkout. Otherwise you may have already # customised mediagoblin.ini to already install these. diff --git a/Dockerfile-fedora-python3-sqlite b/Dockerfile-fedora-python3-sqlite index 72f2874d..be7f30a7 100644 --- a/Dockerfile-fedora-python3-sqlite +++ b/Dockerfile-fedora-python3-sqlite @@ -60,6 +60,15 @@ gstreamer1-plugin-openh264 # RUN apt-get install -y \ # poppler-utils +# Install raw image dependencies. +# TODO + +# Install LDAP depedencies. +RUN dnf -y install python3-ldap + +# Install OpenID dependencies. +RUN dnf -y install python3-openid + RUN groupadd www-data RUN groupadd --system mediagoblin --gid 1024 RUN adduser www-data -g www-data -G mediagoblin @@ -73,14 +82,15 @@ RUN chown root:www-data /var/www USER www-data -RUN git clone --depth=1 https://git.sr.ht/~mediagoblin/mediagoblin --branch ci . +RUN git clone --depth=1 git://git.savannah.gnu.org/mediagoblin.git --branch master . RUN git show --oneline --no-patch RUN ./bootstrap.sh RUN VIRTUALENV_FLAGS='--system-site-packages' ./configure RUN make -RUN ./bin/python -m pytest ./mediagoblin/tests --boxed +RUN echo foo +RUN ./bin/python -m pytest -rs ./mediagoblin/tests --boxed RUN echo '[[mediagoblin.media_types.audio]]' >> mediagoblin.ini RUN echo '[[mediagoblin.media_types.video]]' >> mediagoblin.ini diff --git a/mediagoblin/plugins/openid/README.rst b/mediagoblin/plugins/openid/README.rst index 1a777336..e2792d9a 100644 --- a/mediagoblin/plugins/openid/README.rst +++ b/mediagoblin/plugins/openid/README.rst @@ -20,7 +20,7 @@ This plugin can be enabled alongside :ref:`basic_auth-chapter` and Set up the OpenID plugin ============================ -1. Install the ``python-openid`` package. +1. Install the ``python3-openid`` package. 2. Add the following to your MediaGoblin .ini file in the ``[plugins]`` section:: diff --git a/mediagoblin/tests/test_submission/good.pdf b/mediagoblin/tests/test_submission/good.pdf Binary files differindex d7029f36..13f6fa17 120000..100644 --- a/mediagoblin/tests/test_submission/good.pdf +++ b/mediagoblin/tests/test_submission/good.pdf |