Skip to content

feat(e2e): run tests in dedicated urunc-test namespace#728

Open
mdryaan wants to merge 1 commit into
urunc-dev:mainfrom
mdryaan:feat/e2e-urunc-test-namespace
Open

feat(e2e): run tests in dedicated urunc-test namespace#728
mdryaan wants to merge 1 commit into
urunc-dev:mainfrom
mdryaan:feat/e2e-urunc-test-namespace

Conversation

@mdryaan
Copy link
Copy Markdown
Contributor

@mdryaan mdryaan commented May 27, 2026

Description

nerdctl and ctr e2e tests previously ran in the default containerd namespace, leaving containers and images mixed with host workloads and risking cross-test contamination. This change introduces a dedicated urunc-test namespace: BeforeSuite creates it, AfterSuite removes it, and every nerdctl and ctr command is prefixed with --namespace urunc-test.

crictl is unaffected it uses the k8s.io namespace via the CRI endpoint. docker is unaffected it has its own daemon with no containerd namespace concept.

verifyNoStaleFiles and the namespaceTest config path lookup are also updated to cover the urunc-test namespace.

Related issues

How was this tested?

Build and lint pass locally:

go build ./... # no errors
golangci-lint run --timeout=5m # 0 issues

To verify namespace creation and cleanup on a host with containerd running:

# Before running tests — namespace should not exist yet:
sudo ctr namespaces ls | grep urunc-test || echo "namespace absent"

# Run the test suite (nerdctl or ctr):
make test_nerdctl   # or: make test_ctr

# Namespace exists while tests run:
sudo ctr namespaces ls | grep urunc-test

# After suite completes — AfterSuite removes it:
sudo ctr namespaces ls | grep urunc-test || echo "namespace cleaned up"

# Confirm test images were pulled into urunc-test, not default:
sudo ctr --namespace urunc-test images ls | head -5
sudo ctr images ls | grep -c harbor.nbfc.io || echo "0 images in default"

Full e2e verification requires a host with containerd, nerdctl, and ctr installed alongside a supported VMM (QEMU, Firecracker, or Solo5).

LLM usage

N/A

Checklist

  • I have read the contribution guide.
  • The linter passes locally (make lint).
  • The e2e tests of at least one tool pass locally (make test_ctr, make test_nerdctl, make test_docker, make test_crictl).
  • If LLMs were used: I have read the llm policy.

Signed-off-by: Md Raiyan <alikhurshid842001@gmail.com>
@netlify
Copy link
Copy Markdown

netlify Bot commented May 27, 2026

Deploy Preview for urunc canceled.

Name Link
🔨 Latest commit bbe72a5
🔍 Latest deploy log https://app.netlify.com/projects/urunc/deploys/6a167f3e81e2bb00072d2523

@mdryaan
Copy link
Copy Markdown
Contributor Author

mdryaan commented May 27, 2026

@cmainas PTAL whenever you get a chance.

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.

Run the end-to-end tests in a different namespace

1 participant