fix tests on CI
This commit is contained in:
parent
5b1c615740
commit
04f50ea149
|
@ -14,10 +14,13 @@ type f struct {
|
||||||
|
|
||||||
func Test_fileExists(t *testing.T) {
|
func Test_fileExists(t *testing.T) {
|
||||||
|
|
||||||
|
initStorage()
|
||||||
|
|
||||||
_, err := os.Create(getPlatformStoragePath("exists"))
|
_, err := os.Create(getPlatformStoragePath("exists"))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
defer os.Remove(getPlatformStoragePath("exists"))
|
defer os.Remove(getPlatformStoragePath("exists"))
|
||||||
|
|
||||||
type args struct {
|
type args struct {
|
||||||
|
@ -42,6 +45,8 @@ func Test_fileExists(t *testing.T) {
|
||||||
|
|
||||||
func Test_saveStorageFile(t *testing.T) {
|
func Test_saveStorageFile(t *testing.T) {
|
||||||
|
|
||||||
|
initStorage()
|
||||||
|
|
||||||
file, _ := yaml.Marshal(f{a: 1})
|
file, _ := yaml.Marshal(f{a: 1})
|
||||||
name := "test"
|
name := "test"
|
||||||
|
|
||||||
|
@ -56,6 +61,8 @@ func Test_saveStorageFile(t *testing.T) {
|
||||||
|
|
||||||
func Test_readStorageFile(t *testing.T) {
|
func Test_readStorageFile(t *testing.T) {
|
||||||
|
|
||||||
|
initStorage()
|
||||||
|
|
||||||
file, _ := yaml.Marshal(f{a: 1})
|
file, _ := yaml.Marshal(f{a: 1})
|
||||||
name := "test"
|
name := "test"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue