// TestMultipleKustomizationFiles tests to validate that when multiple kustomization files
// are found, an error is returned
TestMultipleKustomizationFiles tests to validate that when multiple kustomization files
are found, an error is returned
// TestMultipleKustomizationFiles tests to validate that when multiple kustomization files // are found an error is returned
func TestMultipleKustomizationFiles(t *testing.T) {
	   /app
	   ├── kustomization.yaml
	   └── kustomization.yml
	fakeFileSystem := afero.NewMemMapFs()
	fakeFileSystem.Mkdir("app", 0755)
	emptyFileContents := ""
	afero.WriteFile(fakeFileSystem, "app/kustomization.yaml", []byte(emptyFileContents), 0644)
	afero.WriteFile(fakeFileSystem, "app/kustomization.yml", []byte(emptyFileContents), 0644)
	_, err := NewFromFileSystem(fakeFileSystem).GetFromDirectory("app")
	if err == nil {
		t.Errorf("Expected error when reading directory that contains multiple kustomization files")
	}
}
func TestMultipleKustomizationFiles ( t * testing . T ) { fakeFileSystem := afero . NewMemMapFs ( ) fakeFileSystem . Mkdir ( " " , 0755 ) emptyFileContents := " " afero . WriteFile ( fakeFileSystem , " " , [ ] byte ( emptyFileContents ) , 0644 ) afero . WriteFile ( fakeFileSystem , " " , [ ] byte ( emptyFileContents ) , 0644 ) _ , err := NewFromFileSystem ( fakeFileSystem ) . GetFromDirectory ( " " ) if err == nil { t . Errorf ( " " ) } }
TestMultipleKustomizationFiles tests to validate that when multiple kustomization files
are found, an error is returned
TestMultipleKustomizationFiles tests to validate that when multiple kustomization files are found an error is returned
// Folder structure for this test // //   /app //   ├── kustomization.yaml //   └── kustomization.yml