Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flaky unit test #6092

Closed
feloy opened this issue Sep 5, 2022 · 0 comments · Fixed by #6093
Closed

Flaky unit test #6092

feloy opened this issue Sep 5, 2022 · 0 comments · Fixed by #6093
Assignees
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@feloy
Copy link
Contributor

feloy commented Sep 5, 2022

/kind bug

This unit test is flaky:

Based on the files in the current directory odo detected
Language: 
Project type: 
The devfile "" from the registry "" will be downloaded.
--- FAIL: TestInteractiveBackend_PersonalizeName (4.13s)
    --- FAIL: TestInteractiveBackend_PersonalizeName/no_flag (4.12s)
        controller.go:137: missing call(s) to *asker.MockAsker.AskName(is anything) /go/odo_1/pkg/init/backend/interactive_test.go:223
        controller.go:137: aborting test due to missing call(s)
panic: runtime error: invalid memory address or nil pointer dereference [recovered]
	panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x18 pc=0x279b492]

goroutine 70 [running]:
testing.tRunner.func1.2({0x321e380, 0x4948500})
	/usr/local/go/src/testing/testing.go:1209 +0x36c
testing.tRunner.func1()
	/usr/local/go/src/testing/testing.go:1212 +0x3b6
panic({0x321e380, 0x4948500})
	/usr/local/go/src/runtime/panic.go:1047 +0x266
github.com/redhat-developer/alizer/go/pkg/apis/recognizer.GetFilePathsFromRoot.func1({0xc00084e270, 0x17}, {0x0, 0x0}, {0xc000675070, 0xc0005100d0})
	/go/odo_1/vendor/github.com/redhat-developer/alizer/go/pkg/apis/recognizer/language_recognizer.go:125 +0x132
path/filepath.walk({0x3488d3e, 0x4}, {0x38eede8, 0xc0005100d0}, 0xc0006b5070)
	/usr/local/go/src/path/filepath/path.go:438 +0x2a3
path/filepath.Walk({0x3488d3e, 0x4}, 0xc000675070)
	/usr/local/go/src/path/filepath/path.go:505 +0x85
github.com/redhat-developer/alizer/go/pkg/apis/recognizer.GetFilePathsFromRoot({0x3488d3e, 0x4})
	/go/odo_1/vendor/github.com/redhat-developer/alizer/go/pkg/apis/recognizer/language_recognizer.go:116 +0xdf
github.com/redhat-developer/alizer/go/pkg/apis/recognizer.Analyze({0x3488d3e, 0x4})
	/go/odo_1/vendor/github.com/redhat-developer/alizer/go/pkg/apis/recognizer/language_recognizer.go:36 +0x158
github.com/redhat-developer/alizer/go/pkg/apis/recognizer.detectComponent({0x3488d3e, 0x4}, {0xc0006b5918, 0x0, 0x0})
	/go/odo_1/vendor/github.com/redhat-developer/alizer/go/pkg/apis/recognizer/component_recognizer.go:237 +0x9a
github.com/redhat-developer/alizer/go/pkg/apis/recognizer.getComponentsWithoutConfigFile({0xc00038ed50, 0x1, 0x0})
	/go/odo_1/vendor/github.com/redhat-developer/alizer/go/pkg/apis/recognizer/component_recognizer.go:66 +0xee
github.com/redhat-developer/alizer/go/pkg/apis/recognizer.DetectComponents({0x3488d3e, 0x4})
	/go/odo_1/vendor/github.com/redhat-developer/alizer/go/pkg/apis/recognizer/component_recognizer.go:51 +0x8b
github.com/redhat-developer/odo/pkg/alizer.DetectName({0x3488d3e, 0x4})
	/go/odo_1/pkg/alizer/alizer.go:92 +0x94
github.com/redhat-developer/odo/pkg/init/backend.(*InteractiveBackend).PersonalizeName(0xc0006b5d38, {{{0x0, 0x0}, {0x3488d3e, 0x11}, {0x0, 0x0}, {0x0, 0x0, 0x0}, ...}, ...}, ...)
	/go/odo_1/pkg/init/backend/interactive.go:126 +0x69
github.com/redhat-developer/odo/pkg/init/backend.TestInteractiveBackend_PersonalizeName.func4(0xc0006d7040)
	/go/odo_1/pkg/init/backend/interactive_test.go:256 +0x2ca
testing.tRunner(0xc0006d7040, 0xc000456b40)
	/usr/local/go/src/testing/testing.go:1259 +0x230
created by testing.(*T).Run
	/usr/local/go/src/testing/testing.go:1306 +0x727
FAIL	github.com/redhat-developer/odo/pkg/init/backend	4.797s
@openshift-ci openshift-ci bot added the kind/bug Categorizes issue or PR as related to a bug. label Sep 5, 2022
@feloy feloy self-assigned this Sep 5, 2022
@feloy feloy added this to odo v3.0.0 Sep 5, 2022
@feloy feloy moved this to For Review in odo v3.0.0 Sep 5, 2022
Repository owner moved this from For Review to Done in odo v3.0.0 Sep 6, 2022
@rm3l rm3l added the v3 label Oct 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants