Skip to content

cp

cp #3

Workflow file for this run

# CI build to validate PR changes before merging
name: cp
# Controls when the action will run.
on:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Set the cp.icr.io ace container as runtime.
container:
image: cp.icr.io/cp/appc/ace:12.0.11.0-r1
credentials:
username: ${{ secrets.CP_USERNAME }}
password: ${{ secrets.CP_PASSWORD }}
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4
- name: Build the application and test it
shell: bash
run: |
echo "Loading ACE profile"
export LICENSE=accept
set +e # Don't fail on error if the profile has already been loaded
. /opt/ibm/ace-12/server/bin/mqsiprofile
set -e # Fail on error - this must be done after the profile in case the container has the profile loaded already
echo ========================================================================
echo Building application
echo ========================================================================
# Using --compile-maps-and-schemas for 12.0.11 and later . . .
ibmint package --input-path . --output-bar-file $PWD/tea-application-combined.bar --project TeaSharedLibraryJava --project TeaSharedLibrary --project TeaRESTApplication --compile-maps-and-schemas
echo ========================================================================
echo Building unit tests
echo ========================================================================
# Create the unit test work directory
mqsicreateworkdir /tmp/test-work-dir
mqsibar -w /tmp/test-work-dir -a $PWD/tea-application-combined.bar
# Build just the unit tests
ibmint deploy --input-path . --output-work-directory /tmp/test-work-dir --project TeaRESTApplication_UnitTest
echo ========================================================================
echo Running unit tests
echo ========================================================================
IntegrationServer -w /tmp/test-work-dir --no-nodejs --start-msgflows false --test-project TeaRESTApplication_UnitTest