Skip to content

Add /etc/hosts entry for HTTPS tests in CI #7

Add /etc/hosts entry for HTTPS tests in CI

Add /etc/hosts entry for HTTPS tests in CI #7

Workflow file for this run

name: test
# Run the tests when code is pushed to `main`
on:
push:
branches: [ main ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: |
21
- name: Add hosts entry
run: echo "127.0.0.1 local.lattejava.org" | sudo tee -a /etc/hosts
- name: Install Savant Build
run: |
curl -sL savantbuild.org/install | bash
mkdir -p ~/.config/savant/plugins
cat <<EOF > ~/.config/savant/plugins/org.savantbuild.plugin.java.properties
21=${JAVA_HOME_21_X64}
EOF
shell: bash
- name: Run the build
run: |
export JAVA_HOME=${JAVA_HOME_21_X64}
export PATH=~/.local/bin:${JAVA_HOME}/bin:$PATH
sb clean int --excludePerformance --excludeTimeouts
shell: bash
- name: Archive TestNG reports
if: failure()
uses: actions/upload-artifact@v4
with:
name: testng-reports
path: build/test-reports
retention-days: 1