(t *testing.T)
| 79 | ) |
| 80 | |
| 81 | func TestNonExistentCommandLineFile(t *testing.T) { |
| 82 | loadingRules := ClientConfigLoadingRules{ |
| 83 | ExplicitPath: "bogus_file", |
| 84 | } |
| 85 | |
| 86 | _, err := loadingRules.Load() |
| 87 | if err == nil { |
| 88 | t.Fatalf("Expected error for missing command-line file, got none") |
| 89 | } |
| 90 | if !strings.Contains(err.Error(), "bogus_file") { |
| 91 | t.Fatalf("Expected error about 'bogus_file', got %s", err.Error()) |
| 92 | } |
| 93 | } |
| 94 | |
| 95 | func TestToleratingMissingFiles(t *testing.T) { |
| 96 | loadingRules := ClientConfigLoadingRules{ |