This repository was archived by the owner on May 12, 2021. It is now read-only.
Lint backport#1475
Merged
Merged
Conversation
Now, function NewFactory will return nil even create template does't complete. As for this, it will tell user that factory has been initialized no matter whether the template is created or not. This patch correct it by adding another return value of error in NewFactory. Testing initFactoryCommand when enable template will need root privilege to mount tmpfs. So skip it for no-root user. Testing initFactoryCommand func will create template, but no proxy type assigned to VMconfig which will using katabuiltinProxy instead. this will lead to failure for this type of proxy will check proxyparams which contains many null value. This commit fix it by substitute katabuiltinProxy as noopProxy when for test purpose. Fixes: kata-containers#1333 Signed-off-by: Jianyong Wu <jianyong.wu@arm.com>
Fixes: kata-containers#1422 Detect failing test case: ``` .... === RUN TestEnterContainerFailingContNotStarted --- PASS: TestEnterContainerFailingContNotStarted (0.01s) === RUN TestEnterContainer --- FAIL: TestEnterContainer (0.00s) Error Trace: sandbox_test.go:1154 Error: Expected value not to be nil. Messages: Entering non-running container should fail Error Trace: sandbox_test.go:1157 Error: Expected nil, but got: &errors.errorString{s:"Can not move from running to running"} Messages: Failed to start sandbox: Can not move from running to running FAIL ``` `TestEnterContainerFailingContNotStarted` calls `cleanUp` at function begging but it doesn't clean its garbage after it ends. `TestEnterContainer` only call `cleanUp` in the end but it doesn't do cleanUp in the begging, that gives first test case a chance to impact latter one. This commit modifies all the test cases, let them all do the cleanUp() in the end. The policy here is: "everyone needs to take their garbage away when they leave" :) Signed-off-by: Wei Zhang <zhangwei555@huawei.com>
do cleanup inside startVM() if start vm get error Fixes: kata-containers#1426 Signed-off-by: Ace-Tang <aceapril@126.com>
update architecture.md link, since it has moved to within the design/ directory. Fixes: kata-containers#1462 Signed-off-by: Gabi Beyer <Gabrielle.n.beyer@intel.com>
Like shim, we should validate the proxy path if it is provided. Fixes: kata-containers#1424 Signed-off-by: Peng Tao <bergwolf@hyper.sh>
gometalinter is deprecated and will be archived April '19. The suggestion is to switch to golangci-lint which is apparently 5x faster than gometalinter. Partially Fixes: kata-containers#1377 Signed-off-by: Ganesh Maharaj Mahalingam <ganesh.mahalingam@intel.com> (cherry picked from commit f442876)
After we switched golang linter to golangci-lint, we has extra 'deadcode' linter check, and we need to remove this linter check for all generic items. Fixes: kata-containers#1432 Signed-off-by: Penny Zheng <penny.zheng@arm.com> (cherry picked from commit 2e5194e)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Testing if linter changes will fix 1.6 backports.