Skip to content
This repository has been archived by the owner on Sep 14, 2023. It is now read-only.

Implement integration test cases for rest of current contract entry points #7

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

rpatel-figure
Copy link
Collaborator

@rpatel-figure rpatel-figure commented Jan 18, 2023

Context

Follow-up to #6 to

  • increase the code coverage of the integration tests to the remaining execute and query entry points which are currently defined in the contract's main branch
  • clean up the test code that was in the project before Update library to be compatible with the contract's first iteration #6 to use Kotest assertions and/or be deleted if they don't make sense to have anymore
  • let the CI workflow take a GitHub tag of the smart contract repository as an input to the integration tests

Changes

  • Update some KDocs
  • Add and implement a method for executing the "update settings" entrypoint
  • Add Provenance accounts to the test environment which can be retrieved as Signers for broadcasting transactions
  • Write test cases for the current execution and query endpoints
  • Add smart contract GitHub version as input to test step in build workflow

@rpatel-figure rpatel-figure added feature A new feature chore An update to configuration or other changes which don't add to or enhance code functionality labels Jan 18, 2023
@github-actions
Copy link

github-actions bot commented Jan 18, 2023

Test Results

13 tests  +3   10 ✔️ +2   18s ⏱️ +6s
  5 suites ±0     3 💤 +1 
  5 files   ±0     0 ±0 

Results for commit f3f9dfb. ± Comparison against base commit 7d5301c.

This pull request removes 2 and adds 5 tests. Note that renamed tests count towards both.
tech.figure.validationoracle.client.client.ContractMetadataIntegrationTest ‑ Updating the contract's settings should
tech.figure.validationoracle.client.client.ValidationDefinitionIntegrationTest ‑ Creating a new validation definition should
tech.figure.validationoracle.client.client.ContractMetadataIntegrationTest ‑ fail when given an invalid new admin address
tech.figure.validationoracle.client.client.ContractMetadataIntegrationTest ‑ succeed when given a valid request
tech.figure.validationoracle.client.client.ValidationDefinitionIntegrationTest ‑ fail if executed by a party other than the contract admin
tech.figure.validationoracle.client.client.ValidationDefinitionIntegrationTest ‑ fail on an invalid validation type
tech.figure.validationoracle.client.client.ValidationDefinitionIntegrationTest ‑ succeed with a valid request body
This pull request removes 2 skipped tests and adds 3 skipped tests. Note that renamed tests count towards both.
tech.figure.validationoracle.client.client.ContractMetadataIntegrationTest ‑ Updating the contract's settings should
tech.figure.validationoracle.client.client.ValidationDefinitionIntegrationTest ‑ Creating a new validation definition should
tech.figure.validationoracle.client.client.ContractMetadataIntegrationTest ‑ succeed when given a valid request
tech.figure.validationoracle.client.client.ValidationDefinitionIntegrationTest ‑ fail on an invalid validation type
tech.figure.validationoracle.client.client.ValidationDefinitionIntegrationTest ‑ succeed with a valid request body

♻️ This comment has been updated with latest results.

@rpatel-figure rpatel-figure force-pushed the ravipatel/increase-integration-test-coverage-1 branch from fe534a8 to f3f9dfb Compare January 19, 2023 00:02
@rpatel-figure rpatel-figure added patch A backwards-compatible bug fix or configuration updates (should follow semantic versioning) and removed feature A new feature labels Jan 30, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
chore An update to configuration or other changes which don't add to or enhance code functionality patch A backwards-compatible bug fix or configuration updates (should follow semantic versioning)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant