add user-defined option in cli integration tests
- Dominant language
- Python
- Stars
- 670
- Forks
- 183
- Avg merge
- 17h 7m
- Merged PRs (30d)
- 358
Description
while working on
#1778
I ran through error that if --pyargs option comes user defined option gets deleted
And I figured out why!
~which means we can independently run test using pytest soley!~
[Link](https://github.com/pytest-dev/pytest/issues/1596)
~in this link it states that conftest.py should be located under folder of testpaths which means we have to fix~
~testpaths option under `pyproject.toml`~~from~
```toml
testpaths = "tests"
markers = [
"integration: Test cases that spawn Dockerized kernel sessions",
]
filterwarnings = [
"ignore::DeprecationWarning:etcd3.*:",
]
asyncio_mode = "auto"
```
~to~
```Java
testpaths = [
"tests",
"src/ai/backend/test"
]
markers = [
"integration: Test cases that spawn Dockerized kernel sessions",
]
filterwarnings = [
"ignore::DeprecationWarning:etcd3.*:",
]
asyncio_mode = "auto"
```
~~
there was confusion on the way! 😢
[Link](https://docs.pytest.org/en/stable/reference/customize.html#initialization-determining-rootdir-and-configfile)

it says we have to fix `pytest.toml` to add options in pytest. since it search only root dir in pytest
https://github.com/lablup/backend.ai/blob/4762bc890eb966d93cdf03f80268319e8521d14b/tests/common/conftest.py#L12
this code will not work!
So I suggest test code should be kept together on one directory! for future test!
JIRA Issue: BA-136
Contributor guide
Assessment
This issue has not been assessed yet.