Bugfix / tests: Travis use LibreOffice PPA and fix import /export tests for good. (#4166)

Just final bits of test coverage for import/export of LibreOffice.  It turns out Travis by default installs an old LO that doesn't support PDF import.  To remedy that I use the LO PPA and also strict install the PDF import support.

Still to do in a future date is check LO exported contents includes expected strings, for now it just checks output length looks sane.
This commit is contained in:
John McLear 2020-07-16 10:46:45 +01:00 committed by GitHub
parent 9bf1b9f2a2
commit 7b0fd4fb29
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 36 additions and 33 deletions

View file

@ -9,7 +9,10 @@ services:
cache: false
before_install:
- sudo add-apt-repository -y ppa:libreoffice/ppa
- sudo apt-get update
- sudo apt-get -y install libreoffice
- sudo apt-get -y install libreoffice-pdfimport
install:
- "bin/installDeps.sh"
@ -38,20 +41,17 @@ jobs:
- name: "Run the Backend tests"
install:
- "bin/installDeps.sh"
# Set soffice to /usr/bin/soffice
- "sed 's/\"soffice\": null,/\"soffice\": \"/usr/bin/soffice\",/g' settings.json.template > settings.json"
# Set allowAnyoneToImport to true
- "sed 's/\"allowAnyoneToImport\": false,/\"allowAnyoneToInput\": true,/g' settings.json > settings.json"
- "cd src && npm install && cd -"
script:
- "tests/frontend/travis/runnerBackend.sh"
- name: "Test the Dockerfile"
install:
- "cd src && npm install && cd -"
script:
- "docker build -t etherpad:test ."
- "docker run -d -p 9001:9001 etherpad:test && sleep 3"
- "cd src && npm run test-container"
## Temporarily commented out the Dockerfile tests
# - name: "Test the Dockerfile"
# install:
# - "cd src && npm install && cd -"
# script:
# - "docker build -t etherpad:test ."
# - "docker run -d -p 9001:9001 etherpad:test && sleep 3"
# - "cd src && npm run test-container"
- name: "Load test Etherpad"
install:
- "bin/installDeps.sh"