kudobuilder / kudobuilder/kuttl
Paths in Kuttl TestSuite should be relative to the TestSuite File
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 824
- Forks
- 103
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 6
Description
**What happened**:
I have a Kuttl Test Suite File:
```
apiVersion: kudo.dev/v1alpha1
kind: TestSuite
manifestDirs:
- ../manifests/
commands:
- command: ../bin/kubectl-kudo init
testDirs:
- ./common
```
This file is located in a folder structure:
```
.
├── bin
│ ├── kubectl-kudo_0.12.0
│ ├── kubectl_1.17.2
├── manifests
│ └── local-path-storage.yaml
└── suites
├── common
│ ├── install-test
│ │ ├── 00-assert.yaml
│ │ ├── 00-install.yaml
│ │ ├── params.yaml
│ │ └── params.yaml.template
│ └── kind-config.yaml
├── kuttl-common.yaml
```
When calling kuttl from a different directory, the manifests, binaries and testDirs are not found because they are looked up relative to the current working directory of the caller.
**What you expected to happen**:
Paths inside a TestSuite file should be relative to that file, not the current working directory of the caller.
**How to reproduce it (as minimally and precisely as possible)**:
Call kuttl with a TestSuite file from another directory.
**Environment**:
- KUTTL version (use `kubectl kuttl version`): 0.2.2
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the TestSuite file-loading and path-resolution entry point, then reproduce the reported invocation from a directory other than the suite's directory. Check how manifestDirs, commands, and testDirs are resolved; done means all three paths resolve relative to the TestSuite file rather than the caller's working directory.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, kubernetes
- Domain
- cli, testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100