diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 74c9ed7..562ecc5 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -17,11 +17,31 @@ jobs: matrix: jdkconf: - JDK 25 + - JDK 21 + - JDK 17 + - JDK 11 + - JDK 8 include: - jdkconf: JDK 25 jdkver: "25" osver: "10" jdkimage: "docker.io/library/eclipse-temurin:25-jdk-ubi10-minimal" + - jdkconf: JDK 21 + jdkver: "21" + osver: "10" + jdkimage: "docker.io/library/eclipse-temurin:21-jdk-ubi10-minimal" + - jdkconf: JDK 17 + jdkver: "17" + osver: "10" + jdkimage: "docker.io/library/eclipse-temurin:17-jdk-ubi10-minimal" + - jdkconf: JDK 11 + jdkver: "11" + osver: "10" + jdkimage: "docker.io/library/eclipse-temurin:11-jdk-ubi10-minimal" + - jdkconf: JDK 8 + jdkver: "8" + osver: "10" + jdkimage: "docker.io/library/eclipse-temurin:8-jdk-ubi10-minimal" steps: - uses: actions/checkout@v3 - name: "Install dependencies" @@ -32,7 +52,7 @@ jobs: run: | podman --version podman run --rm -it ${{matrix.jdkimage}} bash --version - podman run --rm -it ${{matrix.jdkimage}} java --version + podman run --rm -it ${{matrix.jdkimage}} java -version podman run --rm -it ${{matrix.jdkimage}} cat /etc/redhat-release - name: RFaS run: | diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c39d1dd --- /dev/null +++ b/.gitignore @@ -0,0 +1,9 @@ +test.1* +test.2* +test.3* +test.4* +test.5* +test.6* +test.7* +test.8* +test.9* diff --git a/README.md b/README.md index 4639938..c66c9c2 100644 --- a/README.md +++ b/README.md @@ -19,9 +19,9 @@ Supported Containers: | UBI 9 | 11 | Runtime | [openjdk-11-runtime](https://catalog.redhat.com/software/containers/ubi9/openjdk-11-runtime/61ee7d1c33f211c45407a91c) | | UBI 9 | 17 | Runtime | [openjdk-17-runtime](https://catalog.redhat.com/software/containers/ubi9/openjdk-17-runtime/61ee7d45384a3eb331996bee) | -How to run the container testsuite. - -TODO +## How to run the container testsuite. +eg: `RFAT_RERUNS=1 WHITELIST=".*" sh run_containerqa.sh --container-image=docker.io/library/eclipse-temurin:8-jdk-ubi10-minimal` +Generally you need some container inage.... Consult GHAs for more hints. ## Cryptographic Algorithms/Providers Testing The tests 700 - 705 are made for testing whether the Red Hat's Build of OpenJDK containers are FIPS-compatible and behave as expected (for example when setting FIPS in the container manually). diff --git a/containersQa/026_reproducerOPENJDK-390_checkJavaHomeEnvVarValid.sh b/containersQa/026_reproducerOPENJDK-390_checkJavaHomeEnvVarValid.sh index 5e4dab9..ce8d6db 100644 --- a/containersQa/026_reproducerOPENJDK-390_checkJavaHomeEnvVarValid.sh +++ b/containersQa/026_reproducerOPENJDK-390_checkJavaHomeEnvVarValid.sh @@ -20,4 +20,6 @@ processArguments setup echo "Verifier for Jira Ticket: OPENJDK-390." | tee $REPORT_FILE echo "Jira Link: https://issues.redhat.com/browse/OPENJDK-390" | tee -a $REPORT_FILE -checkJavaHomeEnvVarValid 2>&1| tee -a $REPORT_FILE \ No newline at end of file +checkJavaHomeEnvExists 2>&1| tee -a $REPORT_FILE +checkJavaHomeEnvIsFile 2>&1| tee -a $REPORT_FILE +checkJavaHomeEnvVarValid 2>&1| tee -a $REPORT_FILE diff --git a/containersQa/testlib.bash b/containersQa/testlib.bash index c991c51..7ac4c08 100644 --- a/containersQa/testlib.bash +++ b/containersQa/testlib.bash @@ -987,10 +987,23 @@ function checkJavaHomeEnvVar() { runOnBaseDir bash -c 'echo $JAVA_HOME' } +function checkJavaHomeEnvExists() { + runOnBaseDir bash -c 'ls -l $JAVA_HOME' + runOnBaseDir bash -c 'ls -l $JAVA_HOME/bin' + runOnBaseDir bash -c 'ls -l $JAVA_HOME/bin/java' +} + +function checkJavaHomeEnvIsFile() { + runOnBaseDir bash -c 'test -d $JAVA_HOME' + runOnBaseDir bash -c 'test -d $JAVA_HOME/bin' + runOnBaseDir bash -c 'test -f $JAVA_HOME/bin/java' +} + function checkJavaHomeEnvVarValid() { runOnBaseDir bash -c '$JAVA_HOME/bin/java -version' } + function otherUserRun() { set +e #There is no test here. The call's output must be checked.