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

Texlive more tests #1027

Merged
merged 2 commits into from Aug 7, 2018
Merged

Conversation

tkw1536
Copy link
Contributor

@tkw1536 tkw1536 commented Aug 2, 2018

This commit completly overhauls the way Travis tests are done. Previously, these were used by manually installing appropriate versions of perl and tex into the testing environment and then running a script.

This commit introduces a scheme for building appropriate docker test runtime images.
This allows for a lot more flexibility and reliable when running tests.
It also makes the tests run faster, as it is no longer neccessary to download, install and configure several dependencies.
These images are then pulled and used by Travis at testing time.

This commit completly overhauls the way Travis tests are done.
Previously, these were used by installing appropriate versions of perl
and tex into the testing environment and then running a script.

This commit introduces a scheme for building appropriate docker test
runtime images. This allows for a lot more flexibility and reliable when
running tests. It also makes the tests run faster, as it is no longer
neccessary to download, install and configure several dependencies.
Now that the Travis Tests have been updated to a newer version of
TeXLive, we can re-enable the csquotes babel test.
@@ -6,7 +6,7 @@ use LaTeXML::Util::Test;

latexml_tests("t/babel",
requires=>{'*'=>['babel.sty','babel.def'],
csquotes=>['skipbecauseofoldtexliveintravis', 'csquotes.sty', 'frenchb.ldf', 'germanb.ldf'],
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i like this change 😂



To build all test images required by the tests, the `src/build-all.sh` can be used.
After building, this script will upload each image to [latexml/latexml-test-runtime](https://hub.docker.com/r/latexml/latexml-test-runtime/) on DockerHub.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cool, 👍 for the DockerHub approach here, very manageable


source /usr/local/perlbrew/etc/bashrc

Afterwards, you can run any test command manually.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great Readme, makes perfect sense to me.

ENV PERL $PERL

# run the installation of the given version of perl
RUN /bin/bash -c "source /usr/local/perlbrew/etc/bashrc; perlbrew --notest install $PERL; perlbrew clean; perlbrew switch $PERL"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, perlbrew --notest is a wise approach to speed things along, I am just jotting down that I have had perlbrew's Perl tests fail on old OS-es (Hulk in particular), so it's not always foolproof... but if the tests pass after, it must have worked well anyway?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I mostly added it to speed up the repetitive docker builds (when building all runtime images at once), and it has worked so far.

libdb-dev \
libxml2-dev \
libxslt1-dev \
zlib1g-dev
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One tricky bit is to remember to keep this file up-to-date as we keep developing if dependencies are added. I guess the good news is that the travis tests will fail when it is out of date, so we can't quite forget to 👍

@brucemiller brucemiller merged commit 2652a23 into brucemiller:master Aug 7, 2018
@tkw1536 tkw1536 deleted the texlive-more-tests branch August 8, 2018 15:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants