Skip to content

Commit

Permalink
skip test error
Browse files Browse the repository at this point in the history
Signed-off-by: Leclerc Clement <[email protected]>
  • Loading branch information
clementleclercRTE committed Nov 18, 2024
1 parent e9a05ef commit 1f7b1d1
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/snapshot-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -245,3 +245,44 @@ jobs:
with:
name: pypowsybl-wheel-${{ matrix.config.name }}-${{ matrix.python.name }}
path: dist/*.whl
- name: Upload wheel
uses: actions/upload-artifact@v3
with:
name: pypowsybl-wheel-${{ matrix.config.name }}-${{ matrix.python.name }}
path: dist/*.whl

# Add test summary step
- name: Generate Test Summary
if: always()
run: |
echo "### Test Execution Summary 📊" >> $GITHUB_STEP_SUMMARY
# Function to check maven log for failures
check_maven_log() {
local module=$1
local log_file="$module/target/surefire-reports/TEST-*.xml"
if ls $log_file 1> /dev/null 2>&1; then
echo "#### $module Test Results" >> $GITHUB_STEP_SUMMARY
failed_tests=$(grep -l "failures=\"[1-9]" $log_file || true)
if [ ! -z "$failed_tests" ]; then
echo "❌ Failed Tests:" >> $GITHUB_STEP_SUMMARY
for test in $failed_tests; do
classname=$(grep "testcase classname" $test | head -1 | sed 's/.*classname="\([^"]*\)".*/\1/')
echo "- $classname" >> $GITHUB_STEP_SUMMARY
done
else
echo "✅ All tests passed" >> $GITHUB_STEP_SUMMARY
fi
echo "" >> $GITHUB_STEP_SUMMARY
fi
}
# Check each module
check_maven_log "powsybl-core"
check_maven_log "powsybl-open-loadflow"
check_maven_log "powsybl-diagram"
check_maven_log "powsybl-enstoe"
check_maven_log "powsybl-openrao"
check_maven_log "powsybl-dynawo"
check_maven_log "powsybl-dependencies"

0 comments on commit 1f7b1d1

Please sign in to comment.