Skip to content

Commit

Permalink
Archived fixtures/udev similar to fixtures/sys to avoid go-get errors,
Browse files Browse the repository at this point in the history
…fixes prometheus#2482 (prometheus#2485)

Signed-off-by: Darshil Chanpura <darshil@thatwebsite.xyz>
  • Loading branch information
dtchanpura authored and oblitorum committed Apr 9, 2024
1 parent 5cec10e commit 0e24caa
Show file tree
Hide file tree
Showing 18 changed files with 536 additions and 465 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,6 @@ dependencies-stamp
vendor/
# Test files extracted from ttar
collector/fixtures/sys/
collector/fixtures/udev/

/vendor
9 changes: 6 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,12 @@ $(eval $(call goarch_pair,mips64el,mipsel))
all:: vet checkmetrics checkrules common-all $(cross-test) $(test-e2e)

.PHONY: test
test: collector/fixtures/sys/.unpacked
test: collector/fixtures/sys/.unpacked collector/fixtures/udev/.unpacked
@echo ">> running tests"
$(GO) test -short $(test-flags) $(pkgs)

.PHONY: test-32bit
test-32bit: collector/fixtures/sys/.unpacked
test-32bit: collector/fixtures/sys/.unpacked collector/fixtures/udev/.unpacked
@echo ">> running tests in 32-bit mode"
@env GOARCH=$(GOARCH_CROSS) $(GO) test $(pkgs)

Expand All @@ -110,9 +110,12 @@ skip-test-32bit:
update_fixtures:
rm -vf collector/fixtures/sys/.unpacked
./ttar -C collector/fixtures -c -f collector/fixtures/sys.ttar sys
rm -vf collector/fixtures/udev/.unpacked
./ttar -C collector/fixtures -c -f collector/fixtures/udev.ttar udev


.PHONY: test-e2e
test-e2e: build collector/fixtures/sys/.unpacked
test-e2e: build collector/fixtures/sys/.unpacked collector/fixtures/udev/.unpacked
@echo ">> running end-to-end tests"
./end-to-end-test.sh

Expand Down
Loading

0 comments on commit 0e24caa

Please sign in to comment.