Skip to content

CLIENT-2993 & CLIENT-2994 #45

CLIENT-2993 & CLIENT-2994

CLIENT-2993 & CLIENT-2994 #45

name: Run Unit Tests
on:
pull_request:
branches:
- dev
jobs:
test-normal:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py
pip install -r requirements.txt
working-directory: tests
- name: Retrieve the secret and decode it to a file
env:
FEATURE_FILE: ${{ secrets.FEATURE_FILE }}
run: |
echo $FEATURE_FILE | base64 --decode > features.conf
working-directory: tests
- name: Docker Login
uses: docker/login-action@v2
with:
registry: aerospike.jfrog.io
username: ${{ secrets.JFROG_USERNAME }}
password: ${{ secrets.JFROG_PASSWORD }}
- name: Run unit tests
run: |
docker run -d --network=host -p 5000:5000 --name aerospike-proximus -v ./aerospike-proximus.yml:/etc/aerospike-proximus/aerospike-proximus.yml -v ./features.conf:/etc/aerospike-proximus/features.conf aerospike.jfrog.io/docker/aerospike/aerospike-proximus-private:0.5.0-SNAPSHOT
docker run -d --name aerospike -p 3000:3000 -v .:/etc/aerospike aerospike/aerospike-server-enterprise:latest
sleep 10
docker ps
python -m pytest standard/sync -s --host 0.0.0.0 --port 5000
working-directory: tests
test-tls-auth:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py
pip install -r requirements.txt
working-directory: tests
- name: Retrieve the secret and decode it to a file
env:
FEATURE_FILE: ${{ secrets.FEATURE_FILE }}
run: |
echo $FEATURE_FILE | base64 --decode > features.conf
working-directory: tests
- name: Docker Login
uses: docker/login-action@v2
with:
registry: aerospike.jfrog.io
username: ${{ secrets.JFROG_USERNAME }}
password: ${{ secrets.JFROG_PASSWORD }}
- name: create config
run: |
assets/call_gen.sh
working-directory: tests
- name: Run unit tests
run: |
docker run --network=host -p 5000:5000 -v $(pwd)/aerospike-proximus.yml:/etc/aerospike-proximus/aerospike-proximus.yml -v $(pwd)/features.conf:/etc/aerospike-proximus/features.conf -v $(pwd)/tls:/etc/aerospike-proximus/tls aerospike.jfrog.io/docker/aerospike/aerospike-proximus-private:0.5.0-SNAPSHOT
docker run -d --name aerospike -p 3000:3000 -v .:/etc/aerospike aerospike/aerospike-server-enterprise:latest
sleep 10
docker ps
python -m pytest standard/sync -s --host brawn --port 5000 -root_certificate root.crt --private_key brawn.key.pem --certificate_chain brawn.crt -vs
working-directory: tests