diff --git a/rest_test.go b/rest_test.go index 8b0ae1d..0496c83 100644 --- a/rest_test.go +++ b/rest_test.go @@ -7,6 +7,7 @@ import ( "net/http" "net/http/httptest" "net/http/httputil" + "os" "regexp" "strings" "testing" @@ -309,6 +310,19 @@ func TestRestError(t *testing.T) { } } +func TestRepoFiles(t *testing.T) { + files := []string{"docker/Dockerfile", "docker/docker-compose.yml", ".env_sample", + ".gitignore", ".travis.yml", ".codeclimate.yml", "CHANGELOG.md", "CODE_OF_CONDUCT.md", + "CONTRIBUTING.md", ".github/ISSUE_TEMPLATE", "LICENSE.md", ".github/PULL_REQUEST_TEMPLATE", + "README.md", "TROUBLESHOOTING.md", "USAGE.md", "USE_CASES.md"} + + for _, file := range files { + if _, err := os.Stat(file); os.IsNotExist(err) { + t.Errorf("Repo file does not exist: %v", file) + } + } +} + func TestLicenseYear(t *testing.T) { t.Parallel() dat, err := ioutil.ReadFile("LICENSE.txt")