Skip to content

fix(config): correct .gitignore test/ path and remove duplicates #85

fix(config): correct .gitignore test/ path and remove duplicates

fix(config): correct .gitignore test/ path and remove duplicates #85

Workflow file for this run

# =============================================================================
# Windows CI Workflow
# =============================================================================
# Purpose:
# Validates library builds and tests pass on Windows platform.
# Runs on every push and PR to main/develop branches.
#
# Tests:
# - Library build
# - Unit tests
# - Integration tests
#
# Platform:
# - Windows Server 2022 (windows-latest)
# - GNAT FSF via Alire
# =============================================================================
name: Windows CI
on:
push:
branches: [main, develop, "feature/**"]
pull_request:
branches: [main, develop]
workflow_dispatch:
inputs:
debug_enabled:
description: 'Enable debug logging'
required: false
default: 'false'
jobs:
windows-build-and-test:
name: Windows Build & Test
runs-on: windows-latest
steps:
# -----------------------------------------------------------------------
# Checkout
# -----------------------------------------------------------------------
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
# -----------------------------------------------------------------------
# Setup Alire
# -----------------------------------------------------------------------
- name: Setup Alire
uses: alire-project/setup-alire@v3
with:
version: 2.0.2
# -----------------------------------------------------------------------
# Replace local pins with GitHub URL pins for CI
# -----------------------------------------------------------------------
- name: Update dependency pins for CI
shell: bash
run: |
# Replace local path pins with GitHub URL pins
# functional v4.0.0, tzif v3.0.3
sed -i "s|functional = { path = '../functional' }|functional = { url = \"https://github.com/abitofhelp/functional.git\", commit = \"d429ad4534d3d19e76f6cf19b0f96fa008925658\" }|" alire.toml
sed -i "s|tzif = { path = '../tzif' }|tzif = { url = \"https://github.com/abitofhelp/tzif_ada.git\", commit = \"e2a782a787a7351ac8776749288ed34d91c5abad\" }|" alire.toml
echo "Updated pins to use GitHub URLs"
echo "=== alire.toml pins ==="
grep -A5 '^\[\[pins\]\]' alire.toml || true
# -----------------------------------------------------------------------
# Build library
# -----------------------------------------------------------------------
- name: Build library
shell: bash
run: |
echo "Building zoneinfo library for Windows..."
alr build -- -j4
echo "Library build complete"
# -----------------------------------------------------------------------
# Build unit tests
# -----------------------------------------------------------------------
- name: Build unit tests
shell: bash
run: |
echo "Building unit tests..."
alr exec -- gprbuild -P test/unit/unit_tests.gpr -p -j4 -XTZIF_OS=windows
echo "Unit tests build complete"
# -----------------------------------------------------------------------
# Build integration tests
# -----------------------------------------------------------------------
- name: Build integration tests
shell: bash
run: |
echo "Building integration tests..."
alr exec -- gprbuild -P test/integration/integration_tests.gpr -p -j4 -XTZIF_OS=windows
echo "Integration tests build complete"
# -----------------------------------------------------------------------
# Run unit tests
# -----------------------------------------------------------------------
- name: Run unit tests
shell: bash
run: |
echo "========================================"
echo "Running Unit Tests"
echo "========================================"
./test/bin/unit_runner.exe
echo "Unit tests complete"
# -----------------------------------------------------------------------
# Run integration tests
# -----------------------------------------------------------------------
- name: Run integration tests
shell: bash
run: |
echo "========================================"
echo "Running Integration Tests"
echo "========================================"
# Use pwd for clean forward-slash path
export TZIF_DATA_PATH="$(pwd)/data/tzif/20251105T093308Z"
echo "TZIF_DATA_PATH=$TZIF_DATA_PATH"
ls -la "$TZIF_DATA_PATH" | head -5
./test/bin/integration_runner.exe
echo "Integration tests complete"
# -----------------------------------------------------------------------
# Test Summary
# -----------------------------------------------------------------------
- name: Test Summary
if: always()
shell: bash
run: |
echo "========================================"
echo "Windows CI Complete"
echo "========================================"
echo "Platform: windows-latest (Windows Server 2022)"
echo "Alire: 2.0.2"
echo ""
echo "Tests executed:"
echo " - Unit tests"
echo " - Integration tests"