Skip to content

Test ping

Test ping #9

name: Docker Image (pre-release)
on:
push:
branches: [ github-actions-test ]
env:
DOTNET_VERSION: '8.0.100' # The .NET SDK version to use
jobs:
test:
runs-on: ubuntu-latest
name: Run Test Cases
services:
mariadb:
image: mariadb:latest
ports:
- 3306:3306
env:
MARIADB_DATABASE: openbudgeteer
MARIADB_USER: openbudgeteer
MARIADB_PASSWORD: openbudgeteer
steps:
- name: Check running container
run: docker ps -a
- name: Verify MariaDB connection
env:
PORT: ${{ job.services.mariadb.ports[3306] }}
run: |
while ! mysqladmin ping -h"127.0.0.1" -P"$PORT" --silent; do
sleep 1
done
- name: Check out repo
uses: actions/checkout@v3
- name: Setup dotnet
uses: actions/setup-dotnet@v3
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Install Blazor dependencies
run: dotnet restore OpenBudgeteer.Blazor
- name: Build Blazor
run: dotnet build OpenBudgeteer.Blazor --configuration Release --no-restore
- name: Run Core Test Cases
env:
CONNECTION_PROVIDER: mariadb
CONNECTION_SERVER: mariadb
CONNECTION_PORT: 3306
CONNECTION_USER: openbudgeteer
CONNECTION_PASSWORD: openbudgeteer
CONNECTION_DATABASE: openbudgeteer
run: dotnet test OpenBudgeteer.Core.Test