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

E2E Enhancements #122

Merged
merged 2 commits into from
Jul 12, 2021
Merged

E2E Enhancements #122

merged 2 commits into from
Jul 12, 2021

Conversation

nguyer
Copy link
Contributor

@nguyer nguyer commented Jul 9, 2021

Resolves https://github.com/hyperledger-labs/firefly/issues/121

This PR adds the ability to run the E2E tests against any FireFly environment. If someone wants to run the tests against a remote FireFly (not on their local dev machine) they will need to create or modify a stack.json file to add some new fields that are not currently added by the CLI. These changes are still backwards compatible with existing stack.json files created by the CLI.

Here's an example of a new stack.json file that points to remote FireFly instances and also uses HTTPS and basic authentication.

{
 "name": "dev",
 "members": [
  {
   "id": "0",
   "index": 0,
   "address": "0xac9c1260fb2ad017de65ce7cf68c0142903357ab",
   "privateKey": "0x02e9b8465ea1b585c2050b1fdf2fbe642c92b74192a0fb6f403ce2d91b5f5fdc",
   "exposedFireflyPort": 443,
   "exposedFireflyAdminPort": 5101,
   "exposedEthconnectPort": 5102,
   "exposedPostgresPort": 5104,
   "exposedDataexchangePort": 5105,
   "exposedIPFSApiPort": 5106,
   "exposedIPFSGWPort": 5107,
   "exposedUiPort ": 5103,
   "fireflyHostname": "zzglm93oa9-zzpl2jzg7u-firefly-os.dev2-ws.photic.io",
   "username": "username1",
   "password": "super-secret-password1",
   "useHttps": true
  },
  {
   "id": "1",
   "index": 1,
   "address": "0xd3ecae28b94b67c3b1651aa6c2efead818b3fca1",
   "privateKey": "0x49733950a87b2d78e6fd768057ccdcf7d957028f7b1fb50b405505d2495d11dd",
   "exposedFireflyPort": 443,
   "exposedFireflyAdminPort": 5201,
   "exposedEthconnectPort": 5202,
   "exposedPostgresPort": 5204,
   "exposedDataexchangePort": 5205,
   "exposedIPFSApiPort": 5206,
   "exposedIPFSGWPort": 5207,
   "exposedUiPort ": 5203,
   "fireflyHostname": "zzglm93oa9-zzmxfv7oo0-firefly-os.dev2-ws.photic.io",
   "username": "username2",
   "password": "super-secret-password2",
   "useHttps": true
  }
 ],
 "swarmKey": "/key/swarm/psk/1.0.0/\n/base16/\n1d699874aebc4e2f4f5ca66346f6e1048a9e5be639a60b374136a0c2b012f5f2",
 "exposedGanachePort": 5100
}

This PR also includes two other, unrelated fixes to database transaction contexts and logging.

@nguyer nguyer requested a review from awrichar July 9, 2021 16:22
@codecov-commenter
Copy link

Codecov Report

Merging #122 (3ce3d04) into main (7485df0) will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##              main      #122   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          181       181           
  Lines         9042      9042           
=========================================
  Hits          9042      9042           
Impacted Files Coverage Δ
internal/batch/batch_processor.go 100.00% <100.00%> (ø)
internal/database/sqlcommon/sqlcommon.go 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7485df0...3ce3d04. Read the comment docs.

@@ -1,5 +1,12 @@
#!/bin/bash -x

set -eo pipefail
Copy link
Contributor

Choose a reason for hiding this comment

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

So much hate for set -u

@nguyer nguyer merged commit 1148dea into main Jul 12, 2021
@nguyer nguyer deleted the e2e-enhancements branch July 12, 2021 12:48
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.

Run E2E tests against any FireFly instances
3 participants