Skip to content

Fix contract integration tests #1144

Closed

Description

@kevindeforth

Background

In #1099 we added two contract integration tests to the code base.

  1. If test_participant_kickout_after_expiration is a unit test, we can skip the last parts of the test (step 6-9) or break them out to a separate unit test. Also the test should be moved from the contract/tests directory closer to the logic they are testing and they should try to use existing helper functions for the VmContext framework to avoid code duplication.
  2. If it's an integration test, it should use the existing sandbox.
  3. The cleanup test is redundant, c.f. chore: index nodes by account id & TLS key in TEE State #1120 (comment)

User Story

No response

Acceptance Criteria

Move the logic to unittests or make an actual integration test
Compare expected NodeIds with actual NodeIds instead of lazily comparing the number of attestations / participants

Resources & Additional Notes

https://nearone.slack.com/archives/C0912BTG51T/p1758187864295229?thread_ts=1758033418.475589&cid=C0912BTG51T

Activity

  1. netrome commented on Sep 18, 2025

    @netrome
    Collaborator

    Note: I would prefer to keep the unit tests. I'd be happy to have them moved and complemented by integration tests but anything that we can test as unit tests should be tested as unit tests, as it provides a much faster feedback loop when debugging and developing.

  2. added
    CIAn issue related to the continuous integration: linters, formatters, tests, etc.
    on Sep 18, 2025
  3. self-assigned this
    on Nov 10, 2025
  4. added a commit that references this issue on Jan 8, 2026
    4530442
  5. linked a pull request that will close this issuetest: fix contract integration tests #1725on Jan 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

CIAn issue related to the continuous integration: linters, formatters, tests, etc.tech-debt

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions