Sign in

Search issue titles and bodies, change requests and comments. Private repositories you cannot read are not included.

vole
Clone

Read only, no credentials:

https://rodent.software/git/vole.git

Write over SSH with a registered key:

git clone ssh://git@0.0.0.0:2222/vole.git

A free and open-source forge that lives in your Git repo.

Code

392 commit(s) on main

Merge change request 01M70WES5ZZDJ6RP226WB11BBZ: Let people rename and remove their own passkeys keenan · 1h ago 4b8c9e1d
history blame raw 1009 B
1package instancerepo
2
3import (
4 "strings"
5 "testing"
6)
7
8// The landing page renders the heading from instance_name, so the starter
9// introduction must not repeat it, and it must point at the repository that
10// holds the file it asks the reader to edit.
11func TestTemplateIntroductionHasNoHeaderAndLinksItsRepository(t *testing.T) {
12 t.Parallel()
13 readme := string(Template("acme-instance")["profile/README.md"])
14 if strings.HasPrefix(strings.TrimSpace(readme), "#") {
15 t.Fatalf("profile/README.md starts with a header: %q", readme)
16 }
17 if !strings.Contains(readme, "`profile/README.md`") ||
18 !strings.Contains(readme, "](/acme-instance)") {
19 t.Fatalf("profile/README.md does not explain how to customize the introduction: %q", readme)
20 }
21}
22
23func TestTemplateIntroductionWithoutARepositoryNameStaysText(t *testing.T) {
24 t.Parallel()
25 readme := string(Template("")["profile/README.md"])
26 if strings.Contains(readme, "](") {
27 t.Fatalf("profile/README.md with no repository name has a link: %q", readme)
28 }
29}
30