Skip to content

Commit 41d2df2

Browse files
authored
Merge pull request #76 from smlx/fix-typo
chore: fix tyop in README
2 parents d212236 + d07ab7f commit 41d2df2

5 files changed

Lines changed: 13 additions & 3 deletions

File tree

.github/workflows/coverage.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
go-version: stable
1717
- name: Calculate coverage
1818
run: |
19-
go test -v -covermode=count -coverprofile=cover.out.raw -coverpkg=./... ./...
19+
go test -v -covermode=atomic -coverprofile=cover.out.raw -coverpkg=./... ./...
2020
# remove mocks from coverage calculation
2121
grep -v mock_ cover.out.raw > cover.out
2222
- name: Generage coverage badge

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
/dist
2+
/cover.out

Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,8 @@ build:
2020
.PHONY: fuzz
2121
fuzz: mod-tidy generate
2222
go test -fuzz='^Fuzz' -fuzztime=10s -v ./internal/server
23+
24+
.PHONY: cover
25+
cover: mod-tidy generate
26+
go test -v -covermode=atomic -coverprofile=cover.out -coverpkg=./... ./...
27+
go tool cover -html=cover.out

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ Then push some code to main:
5858
git checkout --orphan badges
5959
git rm -rf .
6060
rm -f .gitignore
61-
echo 'This branch exists only to contains the coverage badge in the README on `main`.' > README.md
61+
echo 'This branch exists only to store the coverage badge in the README on `main`.' > README.md
6262
git add README.md
6363
git commit -m 'chore: initialize the badges branch'
6464
git push origin badges
@@ -101,7 +101,7 @@ Configure the repository:
101101

102102
1. Go to repository Settings > Rules > Rulesets, and import the `protect-default-branch.json` ruleset.
103103

104-
1. That's it.
104+
That's it.
105105
106106
## How to contribute
107107

internal/server/serve_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@ func TestGreet(t *testing.T) {
4747
expect: "time travel detected",
4848
expectError: true,
4949
},
50+
"late birthday": {
51+
input: []string{"Foo", "2000-12-22"},
52+
expect: "Hello Foo, happy belated birthday for 355 days ago.",
53+
},
5054
}
5155
for name, tc := range testCases {
5256
t.Run(name, func(tt *testing.T) {

0 commit comments

Comments
 (0)