1
0
Fork 0
forked from goffee/goffee
This commit is contained in:
Zeni Kim 2024-09-15 10:06:16 -05:00
parent c97afa7564
commit 7f4e3c39da
4 changed files with 44 additions and 9 deletions

View file

@ -36,7 +36,7 @@ func TestDownloadConfig(t *testing.T) {
func TestDownloadGoCondor(t *testing.T) {
// Prepare
newCmd := CmdNew{}
fileName := "gocondor_temp_" + randstr.Hex(8) + ".tar.gz"
fileName := "cup_temp_" + randstr.Hex(8) + ".tar.gz"
server := httptest.NewServer(http.HandlerFunc(func(rw http.ResponseWriter, req *http.Request) {
res, err := os.ReadFile("testdata/gocondor.tar.gz")
if err != nil {
@ -78,8 +78,8 @@ func TestIsUpdatedRequired(t *testing.T) {
func TestUnpack(t *testing.T) {
// Prepare
cn := CmdNew{}
filepath := "./testdata/gocondor.tar.gz"
folderName := "gocondor-0.3-alpha.6"
filepath := "./testdata/cup.tar.gz"
folderName := "cup-0.3-alpha.6"
destPath := os.TempDir()
os.RemoveAll(destPath + "/" + folderName)