2018-05-25 22:37:44 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -e
|
|
|
|
pwd
|
2019-11-08 00:39:27 +00:00
|
|
|
GORACE="haltonerror=1"
|
|
|
|
go test -race ${1} -coverprofile=model.cover.out -v ./model
|
|
|
|
go test -race ${1} -coverprofile=event.cover.out -v ./event
|
2020-01-13 22:11:00 +00:00
|
|
|
go test -race ${1} -coverprofile=storage.v1.cover.out -v ./storage/v1
|
2019-11-12 20:39:55 +00:00
|
|
|
go test -race ${1} -coverprofile=storage.cover.out -v ./storage
|
2019-11-08 00:39:27 +00:00
|
|
|
go test -race ${1} -coverprofile=peer.connections.cover.out -v ./protocol/connections
|
2021-09-30 00:57:13 +00:00
|
|
|
go test -race ${1} -coverprofile=peer.filesharing.cover.out -v ./protocol/files
|
2018-05-25 22:37:44 +00:00
|
|
|
echo "mode: set" > coverage.out && cat *.cover.out | grep -v mode: | sort -r | \
|
|
|
|
awk '{if($1 != last) {print $0;last=$1}}' >> coverage.out
|
|
|
|
rm -rf *.cover.out
|