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

Fix godog tests #58

Merged
merged 22 commits into from
Feb 5, 2024
Merged

Fix godog tests #58

merged 22 commits into from
Feb 5, 2024

Conversation

andremacedopv
Copy link
Contributor

  • Use godog package to execute tests instead of cli
  • Fix test suite to use golang CCAPI ports and endpoints
  • Fix status code obtaining for tests

andremacedopv and others added 17 commits January 30, 2024 17:33
Signed-off-by: André Macedo <[email protected]>
… of the following contributors: Bruno Andreghetti, Andre Macedo, Mikaella Ferreira, Marcos Sarres,

Lucas Campelo, Aline Lermen and Jamille Peres to this repo subject to the Developer Certificate of Origin (DCO), Version 1.1.

94215ed Merge pull request #46 from GoLedgerDev/develop
2c47cb8 🔨 Isolate goinitus compose file
3d2882d 🐛 Remove command from docker-compose-1org ccapi file
c8332d9 Build ccapi image instead of using go run main.go
b52014b Merge pull request #45 from GoLedgerDev/refactor/remove-rest-server
c4be417 Merge pull request #43 from GoLedgerDev/feature/event
cd3852f Merge branch 'develop' into feature/event
af772a3 ⬆️ Upgrade cc-tools version
2361024 ♻️ Remove node rest-server from repository
a83b2d0 Merge pull request #42 from GoLedgerDev/feature/fabric-gateway
f367aac ✨ Added readOnly option on event
b957ed5 ✨ Tidy test events
89f1b8d ✨ Handle baseLog on ccapi events
1ffbcee ✨ Update CCAPI to register for custom events
bce2d9d Merge branch 'develop' into feature/fabric-gateway
b625fef ⬆️ Bump fabric binaries from 2.5.2 to 2.5.3
9e63538 Fix gateway query endpoint
91a780a Fix getSchema in tryout by removing /
a71e1f1 Make tryout use gateway endpoints
f175d6a Update scripts to deploy network without system channel
e2fc2c9 Update binaries to latest version
d2fbc43 Fix passing transient data
084f4b8 Add possibility to submit tx for specific ondersing orgs without transient
4fe9ea5 Refactor comments on handlers
9e93009 Get transient data properly from request
afbe550 Parse error received from gateway
220dfba Implement query handler via gateway
9dad52f Add remaining invoke routes via gateway
254f466 Add cacertfile to config sdk org 1,2,3
2147f17 Implement handler to invoke chaincode via gateway
df9b19a Fix get proper certs
05392f8 Add cacertfile to config sdk
910cc66 Refactor get certs path
c917506 Merge pull request #41 from GoLedgerDev/develop
dc8dcbd Merge branch 'develop' of https://github.com/GoLedgerDev/cc-tools-demo into develop
70b5105 ⬆️ Bump cc-tools version to v0.8.1
dd1cbbc Merge pull request #40 from GoLedgerDev/refactor/generate-tar
a82d961 Implement invoke via fabric gateway
2014c1b Implement query via fabric gateway
6a1298a Implement functions to connect with fabric gateway
44bc39f Upgrade image tag
2099ea9 Upgrade binary files
25ba626 Add an option for choosing which ccapi to use
3deb1a2 Keep same path to bash binary
7dd9202 Add --name flag to usage description
6f909c5 Ignore tmp folder from generateTar
2a0dbea Add more flexibility to generateTar script
bdfe67d Endorsing policy adjustment for private data collection (secret - org2, org3)
48d8983 Merge branch 'develop' into main
2387edd Change default endorsement
a38a3be Merge pull request #39 from GoLedgerDev/develop
b838fa6 Merge branch 'feature/swaggo' into develop
1ffb553 Add swagger to ccapi-go
dbfecb2 Merge pull request #38 from GoLedgerDev/develop
f7eda52 Add support for @request param in query handler for ccapi
9bc93a0 Merge pull request #36 from GoLedgerDev/develop
b40a5a7 Keep startDev2 calling startDev for compatibility purposes
52e48f4 Update README.md
de65cdb Merge pull request #35 from GoLedgerDev/develop
7fe6b8f Fix tryout transactions failing with 1 org
eb1ea57 Bump ccapi golang version
5bd01f7 Fix upgradeCC for 1 org
0ab2035 Remove support for HLF 1.4 and make 2.2 standard
c5a0dc0 Merge branch 'develop' into main
4c04158 Bump Go version in tests
135edaf Fix invoke retrieval of channel and chaincode names
d8396e0 Fix absence of Go experimentalWorkspaceModule
2c00ab0 Merge pull request #34 from GoLedgerDev/refactor/gopls-settings
76493b2 Remove experimentalWorkspaceModule setting from gopls
852fcf2 Merge pull request #32 from GoLedgerDev/develop
d8216b2 Bump cc-tools to v0.8.0
97f0126 Allow PUT methods in ccapi-go
933edc0 Implement transientMap in ccapi-go
655cd06 Merge pull request #33 from GoLedgerDev/feature/dynamic-assetTypes
3d3b212 ⬆️ Upgrade to acomodate latest cc-tools version
48db386 ⬆️ Upgrade cc-tool version
469cde9 🔧 Call init function on updgradeCC
82fd044 🔥 Remove log
21a9ecb ⬆️ Upgrade cc-tools version
2ff523a Merge branch 'develop' into feature/dynamic-assetTypes
bb65e01 ⬆️ Update cc-tools version on go.mod
50666eb ✨ Track assettype changes on ccapi
91c12be Merge pull request #31 from GoLedgerDev/refactor/generate-tar-2
fa1600f Add label argument to generateTar2 script
55e3e75 Merge pull request #30 from GoLedgerDev/hotfix/ccapi-ports
becffb4 Make ccapi-go ports compatible with tryout
a550cdf ✨ Integration with Dynamic AssetTypes
ef725c5 Merge pull request #29 from GoLedgerDev/develop
0a1183d Merge pull request #21 from GoLedgerDev/feature/fabric2_1-org_script
9e450a1 Fix 1 org script and adjust for new ccapi in Go
6b0faa4 Merge branch 'main' into feature/fabric2_1-org_script
de88b93 Merge pull request #28 from GoLedgerDev/develop
fa4b47b Update README.md
4ffb4d3 Merge pull request #27 from GoLedgerDev/feature/ccapi-go
a05654e Merge branch 'develop' into feature/ccapi-go
b57507e Merge pull request #26 from GoLedgerDev/hotfix/ccUninstalledError
813b64d Merge pull request #25 from GoLedgerDev/hotfix/dockerComp
7252dd2 Fix query in case cc not installed
cec9095 Add retry for chaincode uninstalled in org peer
a6df1b3 Finish support legacy endpoints & support GoInitus
b7d2acc Support legacy endpoint for GoInitus compatibility
a1bdf52 Implement initial version of CCAPI in Go
6711750 Fix project name flag not being supported
3380f95 Merge pull request #24 from GoLedgerDev/course
fa24531 Rest api adjustments
8768621 Rest api adjustments
761a9ef Merge remote-tracking branch 'origin/develop' into main
9ebfba0 Add generateTemplateTar2
5723fd3 Merge branch 'feature/fabric-2x-gen-tar' into develop
7572dc9 Merge pull request #22 from GoLedgerDev/develop
939fdda Merge pull request #20 from GoLedgerDev/feature/godog_tests
0f32b82 Small improvements
1b2ec5f Add timeout in waitForNetwork
c93c334 ✨ Make tests more independent and allow to only verify is a test network is running
9568cb5 Merge branch 'feature/godog_tests' into feature/fabric2_1-org_script
a98e3ea ✨ Finish fabric2 script for 1 org
78c3199 🚧 Update fabric2 script to work with 1 org
ec0d07d Change wait for network in godog test
db3a5bb Merge branch 'feature/godog_tests' into feature/fabric2_1-org_script
e033631 🧑‍💻 Create script to run godogo
358b5ba 📝 Update readme with details to run with only 1 org
250be94 💬 Correct flag on usage example on startDev
263b70a 🐛 Correct endorsement for 1 organization mode on script
1ab2cf9 🔥 Remove exit from startDev script
5e4e27b Adjust some chaincode permissions and startDev script
c174fc0 Update fabric startDev script to allow 1 or 3 orgs
ceca91c 🚧 WIP: Change create orgs to accept multiple org quantities
3cca987 🚸 Optionally disable clear containers on down mode
f328cc9 🔨 Update upgradeCC script to allow 1 to 3 organizations
0cd4130 🔨 Make rest server startDev script sccept 1 to 3 organizations
f6d302c Edit permissions to consider when there's only 1 org for godog tests
9d60a91 ⚡ Improve godog test speed
1638916 Create godog feature updateBookTentant
e6872b7 Create godog feature getNumberOfBooksFromLibrary
0a8e3c3 ✅ Test createNewLibrary when a library already exists with same name
6b7b56d ✅ Multiple scenarios for getBooksByAuthor tx
b375476 Merge branch 'feature/godog_tests' of https://github.com/GoLedgerDev/cc-tools-demo into feature/godog_tests
1a8cdbc ✅ Create test for getBooksBuAuthor transaction
19f4ed2 Implement compare response fields in godog test
ddda92f 🐛 Wait for ccapi to be ready to continue execution
d9fc3ba Fix request body in feature
04c8031 🔀 Merge all godog auxiliary methods
aa7bfdf Implement theResponseShouldMatchJson and thereIsARunningTestNetwork
49f17b3 ✅ Create Request With and Response Code methods for godog
fe4e531 Create first feature
490ab27 Remove print
92db1a7 Add custom data type with iota enum as example
87b2bce Merge pull request #19 from GoLedgerDev/develop
c80fe6b Merge pull request #17 from GoLedgerDev/feature/searchTx
28a9766 Fix go.sum
50a6912 Make code more readable
a31c0d4 Search books by author tx
1d2c3b3 Merge pull request #16 from GoLedgerDev/develop
01ed245 Add generateTar with fabric 2.x support
94ac2c0 Merge pull request #9 from GoLedgerDev/refactor/script-generate-certs
022bfa1 Merge pull request #14 from GoLedgerDev/develop
9bac2d0 Quality of life change, now GoInitus has a docker-compose file
2a19fee Merge pull request #13 from GoLedgerDev/fix/env
61e7528 Check if DEPLOY or DOCKER to define port
08a7108 Changed DEPLOY=1 to DOCKER=1
d71bc69 Merge pull request #12 from GoLedgerDev/develop
5fa5528 Update dependencies
d89a087 Add quality of life docker-compose file
8a15cbc Change envvar to stay consistent with GoFabric part 2
f2095f4 Implement simple Basic auth
9664a57 Change envvar to stay consistent with GoFabric
d3fae11 Merge branch 'update/v0.7.2' into develop
cb3182a Merge branch 'fix/improveTarArgs' into develop
5a0031e Improve arg positions to work on macOS
f4540e3 Update automated tests with @lastupdated verification
4a1ad79 Update cc-tools to v0.7.2
06ce8d3 Merge pull request #10 from GoLedgerDev/fix/removewarning
dc12dd8 remove rest warning and max log size
59ddea6 Remove pseudo TTY from docker exec command
1b8d6aa Merge pull request #8 from GoLedgerDev/refactor/script-generate-template
aa83572 Further improve scripts
3eed332 Script now compress rest-server folder ignoring node_modules
e15f838 Fix new docker version compatibilty
ff237a2 Improve ccapi fault tolerance
cbcd815 Merge pull request #4 from GoLedgerDev/fix/failproof
33fe53e Clean up code
4d805e4 try to select last endorsing peer at initializeChannel
ac90ae0 try to select last endorsing peer at initializeChannel
94a60e9 Add OS verification to fabric2 script
385ae5e Add OS verification before exporting binaries
147abe4 Fix gopls by adding experimental multi-module setting
ad5b7c0 Improve startDev.sh instal chaincode logging
d001289 Include upgradeCC2.sh for Fabric 2.x support
7b7d08d Bump cc-tools to v0.7.1
0b31575 Upgrade cc-tools to v0.7.1-rc.1
9171f73 Merge branch 'feature/fabric2script' into develop
452abc4 Update dependencies
bcfdd1f Review swagger.json
b7cd6a1 Make fabric2 work with private data
6d487c4 Deploy chaincode with private collection
3ddab8f Conditionally vendor chaincode deps
74ba7ca Clear certificates before running fabric2 script
210264d Make fabric2 script work with 3 orgs
adb1c38 Add startDev2.sh script for running test network with Fabric 2.2
92c810a Fix online test
0a9df8f Merge branch 'feature/tests' into develop
662a540 Use cc-tools develop branch
d5b8c08 Include fabric binaries in repo
73e5a20 Conditionally vendor chaincode deps and generate certs
c709cd6 Remove networkCC dependency in startDev.sh
ce014d2 Merge branch 'develop' into main
fd8d969 Add github workflow for running automated tests
940cd95 Finish automated tests
c6fcbb7 Improve automated tryout
2bad710 npmInstall.sh for resolving the grpc package problem
b3ae18a Begin to implement tryout with response checks
b0f6852 Implement automated tests example
95e74e2 Create intermediate container for npm install
05f6f00 Bump cc-tools to v0.7.0-rc.3
94a103d Instantiate and upgrade endorsing policy change
cbac67f Bump cc-tools to v0.7.0-rc.2
430156f Prepare cc-tools-demo for new cc-tools release
b250e82 package.json update
305f7c7 GetMap example
86ac95e Collection and endorsing policies equalized
5f508af Removing package-lock.json
bd8a075 Removing package-lock.json
98c15f9 Correction of updateTenant
098f142 Fabric-samples installed at /home/msarres
5afcd27 Fix mapping of docker.sock
cda7cc7 Adjustments for install pre req
295dab5 InstallPreReq Adjustments
61db40b Merge pull request #2 from GoLedgerDev/feature/installReq
9150b89 Review installPreReq.sh script
4d2cdb1 installPreReq and run-cc-web scripts
ab78fc2 Treat error in main
10806c6 Merge pull request #1 from GoLedgerDev/feature/demonstration
b4c4fa3 Assets person, book, library and secret, and tx adjusted for demonstration
dee10c8 Add renameProject.sh script
3a9a794 Add support for template mode
2082cc3 Bump cc-tools to v0.6.10
e73f68a Bump cc-tools to v0.6.9
62368c8 Bump cc-tools to v0.6.7
45820ca Initial commit

Signed-off-by: Samuel Venzi <[email protected]>
Signed-off-by: André Macedo <[email protected]>
Signed-off-by: Samuel Venzi <[email protected]>
Signed-off-by: André Macedo <[email protected]>
Signed-off-by: André Macedo <[email protected]>
Signed-off-by: Samuel Venzi <[email protected]>
Signed-off-by: André Macedo <[email protected]>
Signed-off-by: Samuel Venzi <[email protected]>
Signed-off-by: André Macedo <[email protected]>
Signed-off-by: Samuel Venzi <[email protected]>
Signed-off-by: André Macedo <[email protected]>
Signed-off-by: Samuel Venzi <[email protected]>
Signed-off-by: André Macedo <[email protected]>
Signed-off-by: Samuel Venzi <[email protected]>
@samuelvenzi samuelvenzi merged commit c26deec into develop Feb 5, 2024
3 checks passed
@samuelvenzi samuelvenzi deleted the fix/godog branch February 5, 2024 20:40
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.

3 participants