mirror of https://github.com/databricks/cli.git
fix acc test prefix
This commit is contained in:
parent
b66b69bc27
commit
3d06fb67e8
|
@ -18,7 +18,7 @@ func assertFileContains(t *testing.T, path string, substr string) {
|
||||||
assert.Contains(t, string(b), substr)
|
assert.Contains(t, string(b), substr)
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestTemplateInitializationForDevConfig(t *testing.T) {
|
func TestAccTemplateInitializationForDevConfig(t *testing.T) {
|
||||||
// create target directory with the input config
|
// create target directory with the input config
|
||||||
tmp := t.TempDir()
|
tmp := t.TempDir()
|
||||||
f, err := os.Create(filepath.Join(tmp, "config.json"))
|
f, err := os.Create(filepath.Join(tmp, "config.json"))
|
||||||
|
@ -48,7 +48,7 @@ func TestTemplateInitializationForDevConfig(t *testing.T) {
|
||||||
assertFileContains(t, filepath.Join(tmp, "development_project", ".github"), "This is a development project")
|
assertFileContains(t, filepath.Join(tmp, "development_project", ".github"), "This is a development project")
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestTemplateInitializationForProdConfig(t *testing.T) {
|
func TestAccTemplateInitializationForProdConfig(t *testing.T) {
|
||||||
// create target directory with the input config
|
// create target directory with the input config
|
||||||
tmp := t.TempDir()
|
tmp := t.TempDir()
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,8 @@ import (
|
||||||
var errSkipThisFile = errors.New("skip generating this file")
|
var errSkipThisFile = errors.New("skip generating this file")
|
||||||
|
|
||||||
var HelperFuncs = template.FuncMap{
|
var HelperFuncs = template.FuncMap{
|
||||||
"skipThisFile": func() error {
|
"skipThisFile": func() (any, error) {
|
||||||
panic(errSkipThisFile)
|
return nil, errSkipThisFile
|
||||||
|
// panic(errSkipThisFile)
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue