Skip to content

feat/generic way to run tests in both VSCode and Github actions#116

Open
farah-t-trigui wants to merge 3 commits intomainfrom
feat/variablize-and-add-test-yml-ressources
Open

feat/generic way to run tests in both VSCode and Github actions#116
farah-t-trigui wants to merge 3 commits intomainfrom
feat/variablize-and-add-test-yml-ressources

Conversation

@farah-t-trigui
Copy link
Contributor

A Github Action workflow that ensures code quality and security before any merge by running unit tests with JaCoCo coverage reporting, static code analysis via SonarQube, CVE and secret scanning via Trivy, and git history secret detection via Gitleaks. Results are published as a step summary in the GitHub Actions UI, artifacts are retained for 14 days, and live badges are pushed to a public Gist for README display.
This workflow will be triggered on push to every branch and on PR to main branch.

@farah-t-trigui farah-t-trigui requested a review from eskenazit March 9, 2026 09:30
@farah-t-trigui farah-t-trigui force-pushed the feat/variablize-and-add-test-yml-ressources branch from 03e2347 to 139160d Compare March 9, 2026 09:40
<artifactId>json-path</artifactId>
<version>2.9.0</version>
</dependency>
<!-- Jackson Core - explicitly set version for compatibility -->
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the argument to remove this comment ?

pom.xml Outdated
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<version>6.0.2</version>
<version>5.10.2</version>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we downgrade the version of this package ?

pom.xml Outdated
<goals>
<goal>shade</goal>
</goals>
<goals><goal>shade</goal></goals>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please align your IDE settings so this is not changed and does not appear in the review

</build>
</profile>
</profiles>

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please align your IDE settings so this is not changed and does not appear in the review

push:
paths:
- 'src/main/resources/schemas/**'
- 'src/test/resources'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add subfolders

pull_request:
paths:
- 'src/main/resources/schemas/**'
- 'src/test/resources'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add subfolders

| grep -o '"status":"[^"]*"' | cut -d'"' -f4)
echo "Attempt $i — status: $STATUS"
[ "$STATUS" = "UP" ] && echo "SonarQube is UP!" && break
sleep 10
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a comment explaining the need to wait for 10 seconds

- name: Export + Publish SonarQube summary
if: always()
run: |
sleep 15
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a comment explaining the need to wait for 15 seconds

@farah-t-trigui farah-t-trigui force-pushed the feat/variablize-and-add-test-yml-ressources branch 2 times, most recently from b8917e1 to c715b86 Compare March 9, 2026 15:20
@farah-t-trigui farah-t-trigui force-pushed the feat/variablize-and-add-test-yml-ressources branch from c715b86 to 47036d0 Compare March 9, 2026 15:54
for file in "$dir"/*.{yaml,yml}; do
[ -f "$file" ] || continue
echo "Validating $file..."
npx --prefix .github ajv validate \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check settings so that it fist on one line

implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>io.naftiko.Capability</mainClass>
</transformer>
<transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"/>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check settings so that it fits in one line

</transformer>
<transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"/>
<transformer
implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check settings so that it fits in one line

@eskenazit
Copy link
Contributor

@jlouvel the src/test/resources/avro-capability.yaml file seems out of date and is blocking merge. Do you want to update it to 0.5 specification or remove it ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants