Refactor cert.go and fiskalhr.go for Public certmenager #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Go | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
FISKALHRGO_TEST_CERT_PATH: ${{ secrets.FISKALHRGO_TEST_CERT_PATH }} | |
FISKALHRGO_TEST_CERT_PASSWORD: ${{ secrets.FISKALHRGO_TEST_CERT_PASSWORD }} | |
FISKALHRGO_TEST_CERT_OIB: ${{ secrets.FISKALHRGO_TEST_CERT_OIB }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: '1.23.1' | |
- name: Build | |
run: go build -v ./... | |
# Decode and save the P12 certificate (needed for tests) | |
- name: Decode and save the P12 certificate | |
run: | | |
echo "$CIS_P12_BASE64" | base64 -d > /tmp/fiskal.p12 | |
env: | |
CIS_P12_BASE64: ${{ secrets.CIS_P12_BASE64 }} | |
- name: Test | |
run: go test -v ./... |