aboutsummaryrefslogtreecommitdiff
path: root/pkg/config/config_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/config/config_test.go')
-rw-r--r--pkg/config/config_test.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/pkg/config/config_test.go b/pkg/config/config_test.go
index c8cd887..7afbaef 100644
--- a/pkg/config/config_test.go
+++ b/pkg/config/config_test.go
@@ -8,17 +8,17 @@ import (
"github.com/google/go-cmp/cmp"
)
-func TestConfig(t *testing.T) {
+func TestFileParsing(t *testing.T) {
testCases := []struct {
name string
config string
- expectedConfig *Configuration
+ expectedConfig *configuration
}{
{
name: "minimal scan",
config: `scan "/srv/git"`,
- expectedConfig: &Configuration{
- Scan: &Scan{
+ expectedConfig: &configuration{
+ Scan: &scan{
Public: true,
Path: "/srv/git",
},
@@ -29,8 +29,8 @@ func TestConfig(t *testing.T) {
config: `scan "/srv/git" {
public false
}`,
- expectedConfig: &Configuration{
- Scan: &Scan{
+ expectedConfig: &configuration{
+ Scan: &scan{
Public: false,
Path: "/srv/git",
},
@@ -41,7 +41,7 @@ func TestConfig(t *testing.T) {
for _, tc := range testCases {
t.Run(tc.name, func(t *testing.T) {
r := strings.NewReader(tc.config)
- config, err := Parse(r)
+ config, err := parse(r)
if err != nil {
t.Fatalf("Error parsing config %s", err.Error())
}