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 tests against actual quetz #6

Open
simonbohnen opened this issue Feb 3, 2023 · 0 comments
Open

Add tests against actual quetz #6

simonbohnen opened this issue Feb 3, 2023 · 0 comments
Assignees

Comments

@simonbohnen
Copy link
Collaborator

By SimonBohnenQC, copied from other repo.

SimonBohnenQC: We're currently not testing against live quetz, right? This would probably be something nice to have.

SimonBohnenQC: It looks to me like the mocked tests are also not reflecting the actual responses given by quetz. Consider the /api/channels/{channel_name}/members route. The mocked tests use the following json scheme:

@pytest.fixture
def expected_channel_members():
return [{"username": "u1", "role": "owner"}, {"username": "u2", "role": "member"}]

Whereas actual quetz specifies the following scheme:

[
  {
    "role": "member",
    "user": {
      "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "username": "string",
      "profile": {
        "name": "string",
        "avatar_url": "string"
      }
    }
  }
]

(You can find it in the Swagger docs when launching quetz)

JanJaguschQC: I had the same thought today when reviewing your PR. I like the idea. Testing against an actual Quetz instance shouldn't be too complicated, either.

@simonbohnen simonbohnen self-assigned this Feb 19, 2023
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

No branches or pull requests

1 participant