Skip to content

Commit

Permalink
adds code coverage analysis (#99)
Browse files Browse the repository at this point in the history
  • Loading branch information
codyfrehr committed Feb 27, 2024
1 parent 04a4805 commit 8d03f92
Show file tree
Hide file tree
Showing 4 changed files with 59 additions and 11 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Codecov
on:
push:
branches: [ 'main' ]
pull_request:
branches: [ 'main' ]

permissions:
contents: read

jobs:
coverage-check:
name: Coverage Check
runs-on: ubuntu-latest
steps:
- name: Setup JDK 8
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'liberica'
- name: Checkout
uses: actions/checkout@v4
- name: Test
run: ./mvnw clean test jacoco:report
- name: Codecov
uses: codecov/codecov-action@v4.0.1
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: codyfrehr/xpdf-api
1 change: 1 addition & 0 deletions README.adoc
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
= Xpdf API

image:https://github.com/codyfrehr/xpdf-api/actions/workflows/ci.yml/badge.svg?event=push&branch=main[]
image:https://codecov.io/gh/codyfrehr/xpdf-api/graph/badge.svg?branch=main[]
image:https://github.com/codyfrehr/xpdf-api/actions/workflows/codeql.yml/badge.svg?event=schedule&branch=main[]
image:https://snyk.io/test/github/codyfrehr/xpdf-api/main/badge.svg[]

Expand Down
17 changes: 6 additions & 11 deletions TODO
Original file line number Diff line number Diff line change
@@ -1,17 +1,9 @@
- should make use of the term "RICH text" or "rich PDF" in your javadocs and readme, and make a special note about how this only works on PDF files with RICH TEXT
- test all code examples from readme and javadocs to ensure they are working!
- figure out how to get github pipeline to run 32-bit architecture (might need to use docker containers...)
- update github project "About" section, and other general settings for the repo
but first, need to get hosting for site and install ssl cert
- reorganize SCRIBBLES into official supporting documents
- write CONTRIBUTING (is this standard name for developer instructions to contribute? DEVELOPERS seems like a better name for file maybe?)
- what other files?
- setup coverage check in pipeline
- setup cve check in pipeline with snyk + add badge to readme
https://github.com/snyk/actions
https://support.snyk.io/hc/en-us/articles/360003997277-Badge-Support-for-Repositories
- set codecov failure threshold. any other configs to be aware of?
- set up github issue management and security management
- fix broken github links on resume and website
- explore and update other general settings for the repo
- figure out process to deploy to maven central repo
- take into consideration repos which provide download statistics: https://blog.sonatype.com/2010/12/now-available-central-download-statistics-for-oss-projects/
- guide: https://maven.apache.org/repository/guide-central-repository-upload.html
Expand All @@ -21,9 +13,12 @@
a good starting point for this would be to find a popular/respected open-source repo using pom configs, and see if they have maven release plugin configured, and how they do it.
- add badge to readme for maven artifact https://search.maven.org/artifact/org.apache.commons/commons-lang3/3.14.0/jar?eh=
- add badge for javadocs https://javadoc.io/
- setup namecheap xpdf.io domain to automatically redirect to github repo, until website built https://www.namecheap.com/support/knowledgebase/article.aspx/385/2237/how-to-set-up-a-url-redirect-for-a-domain/
- request derek to add link to your library on their webpage
- build really basic homepage for website, resembling layout of https://kotest.io/docs or even just the simpler https://mockk.io/, or like that license plugin page
- add dependabot to repo for automatic security updates? not sure how i feel about auto updates...
at very least, make sure notifications set up for failing pipeline security tests.
and make sure repo security well configured, and snyk configured as well as possible (login to snyk website for additional configs)
- fix broken github links on resume and website
- reorganize SCRIBBLES into official supporting documents
- write CONTRIBUTING (is this standard name for developer instructions to contribute? DEVELOPERS seems like a better name for file maybe?)
- what other files?
23 changes: 23 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,25 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.8.11</version>
<executions>
<execution>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>report</id>
<phase>prepare-package</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.mycila</groupId>
<artifactId>license-maven-plugin</artifactId>
Expand Down Expand Up @@ -417,6 +436,10 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
Expand Down

0 comments on commit 8d03f92

Please sign in to comment.