Skip to content

Conversation

@onefloid
Copy link
Collaborator

Summary

Introduces a walking skeleton for fast, deterministic smoke tests in TM1py based on mocked HTTP responses.
The tests run without a TM1 connection.

These smoke tests are intentionally lightweight and are designed to run as part of pull request validation, providing fast feedback and early detection of breaking changes.

Changes

  • Base test: SmokeTestBase.py

    • Starts mocked responses per test
    • Helpers: mock_server_name(), mock_get()
  • Smoke tests:

    • tests/smoke/test_connection_smoke.py --> Verifies get server version, server name, and basic connectivity
    • tests/smoke/test_metadata_smoke.py --> Verifies GET /Dimensionsget_all_names()

How To Run

pytest tests/smoke

@MariusWirtz
Copy link
Collaborator

This makes sense.

Would you prefer to leave this PR in draft mode while we add more smoke tests or merge as is and add more via separate PRs?

@onefloid
Copy link
Collaborator Author

onefloid commented Jan 5, 2026

I think this is mature enough to merge, and it still adds value when we merge it and gain some experience when we run the tests for PR validation.

@nicolasbisurgi
Copy link
Collaborator

I think this makes sense and we can introduce them right away. The only thing I would add with this PR would be documentation: essentially steps, examples, purpose, etc behind these new tests so that the tm1py community can help us build them going forward.
We can add this to the #1325 by adding this to a specific pipeline that happens on each new PR.

Thoughts?

@onefloid
Copy link
Collaborator Author

onefloid commented Jan 5, 2026

Yes, I will add a readme file to the smoke folder. When we reorganize the structure of the tests folder, we should consolidate and rewrite the testing readme files. These documents should explain the various test types, requirements, and how to execute the entire test suite or specific parts. We could also include a section on how to add additional tests.

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.

4 participants