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

Enhancement: Use Sandbox for Testing #363

Merged
merged 18 commits into from
Aug 22, 2022
Merged

Enhancement: Use Sandbox for Testing #363

merged 18 commits into from
Aug 22, 2022

Conversation

tzaffi
Copy link
Contributor

@tzaffi tzaffi commented Aug 17, 2022

Blocked by algorand/algorand-sdk-testing#220

...which explains most of the removed steps.

Additional Unused Steps via Unused Steps Analysis Script

according to this spreadsheet

  • the transaction should still be the same
  • I get transactions by address only
  • I get transactions by address and date
  • @Given("indexer client {int} at {string} port {int} with token {string}")
  • @Given("key registration transaction parameters {int} {int} {int} {string} {string} {string} {int} {int} {int} {string} {string}")
  • @When("I create the payment transaction")
  • @When("I create the key registration transaction")
  • @Then("I can get the transaction by ID")
  • @When("I read a transaction {string} from file {string}")
  • @When("I write the transaction to file")
  • @Then("I do my part")
  • @When("I get recent transactions, limited by {int} transactions")

@tzaffi tzaffi marked this pull request as draft August 17, 2022 16:58
test-harness.sh Outdated Show resolved Hide resolved
test-harness.sh Outdated Show resolved Hide resolved
.test-env Outdated Show resolved Hide resolved
Makefile Outdated Show resolved Hide resolved
Makefile Outdated Show resolved Hide resolved
@tzaffi tzaffi marked this pull request as ready for review August 19, 2022 17:04
.test-env Outdated Show resolved Hide resolved
.test-env Outdated Show resolved Hide resolved
Comment on lines +13 to +24
harness:
./test-harness.sh

docker-javasdk-build:
# Build SDK testing environment
docker build -t java-sdk-testing .

docker-javasdk-run:
# Launch SDK testing
docker run -it --network host java-sdk-testing:latest

docker-test:
./run_integration_tests.sh
docker-test: harness docker-javasdk-build docker-javasdk-run
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Breaking up make docker-test into:

  1. pull down the harness
  2. build the javasdk docker
  3. run the javasdk docker (which runs make unit and make integration)

Comment on lines +1 to +2
UNIT_TAGS := "$(subst :, or ,$(shell awk '{print $2}' src/test/unit.tags | paste -s -d: -))"
INTEGRATION_TAGS := "$(subst :, or ,$(shell awk '{print $2}' src/test/integration.tags | paste -s -d: -))"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cucumber tags now reside in:

  • src/test/integration.tags
  • src/test/unit.tags

Makefile Outdated Show resolved Hide resolved
mvn test -Dtest=com.algorand.algosdk.integration.RunCucumberIntegrationTest -Dcucumber.filter.tags=$(INTEGRATION_TAGS)

display-all-java-steps:
find src/test/java/com/algorand/algosdk -name "*.java" | xargs grep "io.cucumber.java.en" 2>/dev/null | grep -v Binary | cut -d: -f1 | sort | uniq | xargs grep -E "@(Given|Then|When)"
Copy link
Contributor Author

@tzaffi tzaffi Aug 22, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Command that generates input for Unused Steps Analysis script

Copy link
Contributor

@michaeldiamant michaeldiamant left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approval assumes SDK_TESTING_BRANCH reset to master prior to merge.

@tzaffi tzaffi merged commit dc9a4b7 into develop Aug 22, 2022
@tzaffi tzaffi deleted the sandbox-sdk-testing branch August 22, 2022 16:17
ahangsu added a commit that referenced this pull request Sep 2, 2022
* Ignore copied over txt test resource files (#342)

* Github-Actions: Adding pr title and label checks (#339)

* Enhancement: Add UNKNOWN enum type to HTTP client enums. (#351)

* AVM:  Consolidate TEAL and AVM versions (#348)

* Testing: Modify cucumber steps to use dev mode network  (#350)

* DevTools: adding source map decoder (#352)

* adding source map decoder

* bump to 1.17.0

* Enhancement: Use Sandbox for Testing (#363)

* Bugfix: Pass verbosity to the harness and sandbox (#371)

* Enhancement: Deprecating use of langspec (#367)

Co-authored-by: Michael Diamant <[email protected]>

* StateProofs: Add State Proof support. (#360)

* Regenerate client.

* Implement cucumber response tests.

* Implement path tests, update Makefile, update README.

* Revert

* Add state proof fields to Transaction.

* Update README.md

* Update src/main/java/com/algorand/algosdk/transaction/Transaction.java

* publish results.

* Add transaction-root-256

* dummy commit to avoid check pr category

* dummy commit to kill previous dummy commit

Co-authored-by: Michael Diamant <[email protected]>
Co-authored-by: Jack <[email protected]>
Co-authored-by: Will Winder <[email protected]>
Co-authored-by: Ben Guidarelli <[email protected]>
Co-authored-by: Barbara Poon <[email protected]>
Co-authored-by: Zeph Grunschlag <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants