Skip to content

Fix detection if the collector is running as service on Windows #12

Fix detection if the collector is running as service on Windows

Fix detection if the collector is running as service on Windows #12

name: build-and-test-windows
on:
push:
branches: [ main ]
tags:
- 'v[0-9]+.[0-9]+.[0-9]+*'
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: true
jobs:
windows-unittest:
runs-on: windows-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v4
with:
go-version: ~1.20.11
cache: false
- name: Cache Go
uses: actions/cache@v3
env:
cache-name: cache-go-modules
with:
path: |
~\go\pkg\mod
~\AppData\Local\go-build
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
- name: Run Unit Tests
run: make gotest