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

add 'delete' tests #583

Merged
merged 1 commit into from
Mar 2, 2018
Merged

add 'delete' tests #583

merged 1 commit into from
Mar 2, 2018

Conversation

liangchenye
Copy link
Member

No description provided.

@liangchenye
Copy link
Member Author

Based on #580 since it uses 'Kill' in the tests. So #580 should be accepted first.

It does not cover Deleting a container MUST delete the resources that were created during the create step. Note that resources associated with the container, but not created by this container, MUST NOT be deleted. since I don't have a good idea about 'resources' yet.

One issue found in 'runc'. 'runc' could delete a 'created' container, it does not follow Attempting to delete a container that is not stopped MUST have no effect on the container and MUST generate an error. I checked the change log of runtime spec. In opencontainers/runtime-spec#875, it suggests that a user should 'kill' a 'created' container before 'delete' it. But in runc, it will do the 'kill' operation for the user. https://github.com/opencontainers/runc/blob/master/delete.go#L78

@liangchenye
Copy link
Member Author

updated, PTAL @q384566678

cases for DeleteWithoutIDGenError, DeleteNonStopGenError and DeleteNonStopHaveNoEffect

Signed-off-by: Liang Chenye <[email protected]>
@zhouhao3
Copy link

zhouhao3 commented Mar 2, 2018

LGTM

Approved with PullApprove

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants