Skip to content

Commit

Permalink
Update trustchain test for new axios headers
Browse files Browse the repository at this point in the history
  • Loading branch information
lambertkevin committed Aug 19, 2024
1 parent fe738ec commit 8f4ef5a
Show file tree
Hide file tree
Showing 16 changed files with 721 additions and 320 deletions.
66 changes: 44 additions & 22 deletions libs/trustchain/mocks/scenarios/create2trustchainInARow.json

Large diffs are not rendered by default.

57 changes: 38 additions & 19 deletions libs/trustchain/mocks/scenarios/getOrCreateTransactionCases.json

Large diffs are not rendered by default.

69 changes: 46 additions & 23 deletions libs/trustchain/mocks/scenarios/member3implicitlyAdded.json

Large diffs are not rendered by default.

153 changes: 102 additions & 51 deletions libs/trustchain/mocks/scenarios/membersManySelfAdd.json

Large diffs are not rendered by default.

39 changes: 26 additions & 13 deletions libs/trustchain/mocks/scenarios/randomMemberTryToDestroy.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@
"headers": {
"accept": "application/json, text/plain, */*",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
}
},
"response": {
Expand All @@ -49,7 +50,8 @@
"content-length": "1066",
"content-type": "application/json",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
},
"body": "{\"challenge\":{\"version\":0,\"challenge\":{\"data\":\"ce4bf244dc2399f0a12d815ef0ccc339\",\"expiry\":\"2024-07-30T15:08:09Z\"},\"host\":\"trustchain-backend.api.aws.stg.ldg-tech.com\",\"rp\":[{\"credential\":{\"version\":0,\"curveId\":33,\"signAlgorithm\":1,\"publicKey\":\"03cb7628e7248ddf9c07da54b979f16bf081fb3d173aac0992ad2a44ef6a388ae2\"},\"signature\":\"304402203af9870e3bed6b1812328cb8b350d5d4f913c8f2e80d1be86d714d879d40013002205f74f315b718515f2c7de33e8215ed0a42f9bfa6f23717f147306c2ffb2e7dab\"}],\"protocolVersion\":{\"major\":1,\"minor\":0,\"patch\":0}},\"signature\":{\"credential\":{\"version\":0,\"curveId\":33,\"signAlgorithm\":1,\"publicKey\":\"0300b039cd6c9e8eac25de7bb25ad34b7ccd99cbcb9bc966beddc1b57bd61d032b\"},\"signature\":\"3045022100b7040db47e68661aef1cda474afdd8e3666013f9fac5b72ed123e766aabf7aeb02202d863008750d065768ef48c1e10c37693823b9d371c2a87aafcbc0250885c557\",\"attestation\":\"0000210121029a8bef4947807f60aa2130f194f83b45e3989746a40d7b5a027ba13a38c2115f46304402200c90c79c92ee3c7bcb250bf298715ce8cde1a204a3a5363bfbe74336253f3f8c02206f6d11cab73b15321ab15fffa7e9af39d1fc4b2017128219ad9d058e237d7be8\"}}"
},
Expand All @@ -76,7 +78,8 @@
"accept": "application/json, text/plain, */*",
"authorization": "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NiJ9.eyJpc3MiOiJ0cnVzdGNoYWluLWJhY2tlbmQuYXBpLmF3cy5zdGcubGRnLXRlY2guY29tIiwic3ViIjoiMDMwMGIwMzljZDZjOWU4ZWFjMjVkZTdiYjI1YWQzNGI3Y2NkOTljYmNiOWJjOTY2YmVkZGMxYjU3YmQ2MWQwMzJiIiwiYXVkIjpbIkNsb3VkU3luYyIsInRydXN0Y2hhaW4iXSwiZXhwIjoxNzIyMzUwNTkyLCJpYXQiOjE3MjIzNTAyOTEsImp0aSI6ImViZGQ3YjI3LTA5YzQtNDY5Zi1hMTYzLTc5OTgzMmFjZWM0NyIsInBlcm1pc3Npb25zIjp7fSwiZGV2aWNlIjp0cnVlLCJyZWZyZXNoRXhwaXJhdGlvbiI6IjIwMjQtMDctMzBUMTU6Mzg6MTJaIn0.RLmCyNLbe-dcafdjWv3AJ-4Ro5Z3qcxWiCX11iaDFNAxJYCAuAwYF0riFyC_hkZatfNyzp4M8xQJJLx8C4dCnw",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
}
},
"response": {
Expand Down Expand Up @@ -104,7 +107,8 @@
"content-length": "652",
"content-type": "application/json",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
},
"body": "\"0101010220e1d781cf091755ee09e36254c630e954e41ebe797287ba9373f68dbae0ccd06a06210300b039cd6c9e8eac25de7bb25ad34b7ccd99cbcb9bc966beddc1b57bd61d032b01010110b00500010200000621030b3475b759fcd493d1f7175565fccadcfa90850a8b82cb6016792288b8f76631051059086347c2ab2d1c12077c2416fd056f0550a4607c846cdee8cad24b9a17a8b8d51c50f6eb6638ef12ddce33bc2396196dfbd5c0c003bb052450cc0fe7b176e833d36bd35fde5a76def084e7aba22840a75940abad26fc0614e4be50baa7ef8e7a47062103397ac62ef7074f4bb27a0a18e2b542cc4367b7cec97869113ea8a1730d8cbaef0346304402206bc9d2646a1f5be66156c08b64931726b6843cd8fbbb2965519098da6135d6a402206ff57ba2f378e28f73ef2ddc0a4ea0f497653d3328ea36b054da30227e542211\""
},
Expand All @@ -128,7 +132,8 @@
"accept": "application/json, text/plain, */*",
"authorization": "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NiJ9.eyJpc3MiOiJ0cnVzdGNoYWluLWJhY2tlbmQuYXBpLmF3cy5zdGcubGRnLXRlY2guY29tIiwic3ViIjoiMDMwMGIwMzljZDZjOWU4ZWFjMjVkZTdiYjI1YWQzNGI3Y2NkOTljYmNiOWJjOTY2YmVkZGMxYjU3YmQ2MWQwMzJiIiwiYXVkIjpbIkNsb3VkU3luYyIsInRydXN0Y2hhaW4iXSwiZXhwIjoxNzIyMzUwNTkyLCJpYXQiOjE3MjIzNTAyOTEsImp0aSI6ImViZGQ3YjI3LTA5YzQtNDY5Zi1hMTYzLTc5OTgzMmFjZWM0NyIsInBlcm1pc3Npb25zIjp7fSwiZGV2aWNlIjp0cnVlLCJyZWZyZXNoRXhwaXJhdGlvbiI6IjIwMjQtMDctMzBUMTU6Mzg6MTJaIn0.RLmCyNLbe-dcafdjWv3AJ-4Ro5Z3qcxWiCX11iaDFNAxJYCAuAwYF0riFyC_hkZatfNyzp4M8xQJJLx8C4dCnw",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
}
},
"response": {
Expand All @@ -154,7 +159,8 @@
"accept": "application/json, text/plain, */*",
"authorization": "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NiJ9.eyJpc3MiOiJ0cnVzdGNoYWluLWJhY2tlbmQuYXBpLmF3cy5zdGcubGRnLXRlY2guY29tIiwic3ViIjoiMDMwMGIwMzljZDZjOWU4ZWFjMjVkZTdiYjI1YWQzNGI3Y2NkOTljYmNiOWJjOTY2YmVkZGMxYjU3YmQ2MWQwMzJiIiwiYXVkIjpbIkNsb3VkU3luYyIsInRydXN0Y2hhaW4iXSwiZXhwIjoxNzIyMzUwNTk0LCJpYXQiOjE3MjIzNTAyOTMsImp0aSI6ImRhNmJjYWFjLTI3ODgtNDVlZi1hZjZmLTA0NWM0MTZhM2Y2OSIsInBlcm1pc3Npb25zIjp7IjAwZTM5OTY1ZjYzNTJjZTM1ODc0OGE2YzYzODMxNjAzYzU5N2UxYjIzNjQ5N2ZhZDM4ZTU5ODRmOWQ0NzhlYjNjNyI6eyJtLyI6WyJvd25lciJdfX0sImRldmljZSI6dHJ1ZSwicmVmcmVzaEV4cGlyYXRpb24iOiIyMDI0LTA3LTMwVDE1OjM4OjEyWiJ9.5IBwNNeROIIf8y8J3szMfvQ-BIYWQtjbkIBu2qk52MOxrl7zzxbotZwIb6BzidXNxt8d5Fcflni6JwQL06u08A",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
}
},
"response": {
Expand All @@ -180,7 +186,8 @@
"accept": "application/json, text/plain, */*",
"authorization": "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NiJ9.eyJpc3MiOiJ0cnVzdGNoYWluLWJhY2tlbmQuYXBpLmF3cy5zdGcubGRnLXRlY2guY29tIiwic3ViIjoiMDMwMGIwMzljZDZjOWU4ZWFjMjVkZTdiYjI1YWQzNGI3Y2NkOTljYmNiOWJjOTY2YmVkZGMxYjU3YmQ2MWQwMzJiIiwiYXVkIjpbIkNsb3VkU3luYyIsInRydXN0Y2hhaW4iXSwiZXhwIjoxNzIyMzUwNTk0LCJpYXQiOjE3MjIzNTAyOTMsImp0aSI6ImRhNmJjYWFjLTI3ODgtNDVlZi1hZjZmLTA0NWM0MTZhM2Y2OSIsInBlcm1pc3Npb25zIjp7IjAwZTM5OTY1ZjYzNTJjZTM1ODc0OGE2YzYzODMxNjAzYzU5N2UxYjIzNjQ5N2ZhZDM4ZTU5ODRmOWQ0NzhlYjNjNyI6eyJtLyI6WyJvd25lciJdfX0sImRldmljZSI6dHJ1ZSwicmVmcmVzaEV4cGlyYXRpb24iOiIyMDI0LTA3LTMwVDE1OjM4OjEyWiJ9.5IBwNNeROIIf8y8J3szMfvQ-BIYWQtjbkIBu2qk52MOxrl7zzxbotZwIb6BzidXNxt8d5Fcflni6JwQL06u08A",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
}
},
"response": {
Expand Down Expand Up @@ -208,7 +215,8 @@
"content-length": "1120",
"content-type": "application/json",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
},
"body": "\"0101010220e39965f6352ce358748a6c63831603c597e1b236497fad38e5984f9d478eb3c706210300b039cd6c9e8eac25de7bb25ad34b7ccd99cbcb9bc966beddc1b57bd61d032b01010315b8050c80000000800000108000000006210313a9015c0a50eb30c42cdb52dfa0026f441c610099e8439d2d0db7a9c99c87a30510b5e4d33136149189ca980b808cdc1a9d05508ec84ac1dd4916cf23e282be59179d992abf1c45369d82ae658daa36b658adbfd6784b54104f1365d7cdfd2aa5cac2237325c6b89b885482c745c80bb95cf6dd348e0553dba48c3966b4dd41c002318a0621023250865a9440306b8f47f364f900f9e8b890b3e6ac729c458251c48bb9b133d8113304084d656d6265722031062103843c26fa5c75f465586722218a6e81fe96d50b3ef73d787e52cf432264c5adf10104ffffffff12aa0510669133f6457f734638ea00ac4cc48f240550a25366850fa609221e7a5a94b40ddd84e82245b91ff01246b80b3d010f0285930e7ff52c03bf405906e777717543b49d01967e07b8105adce83128371f5f93fe9a0c182e4d6c3211e9d9aee5d67fc294062103843c26fa5c75f465586722218a6e81fe96d50b3ef73d787e52cf432264c5adf10621022b9fb46af7c6d0e7c6ae1ca0935cff9b303697bad99a329c7476673e5591492403473045022100fad06ad0458699f8b44ae2d0435f3c4de0ecd39a5d9226c5bf43690ee696600f02205f507ce323cb716355ceb760a74f954c7a330c5f47bcac9053fa8b56f8353f50\""
},
Expand All @@ -231,7 +239,8 @@
"headers": {
"accept": "application/json, text/plain, */*",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
}
},
"response": {
Expand All @@ -258,7 +267,8 @@
"content-length": "986",
"content-type": "application/json",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
},
"body": "{\"challenge\":{\"version\":0,\"challenge\":{\"data\":\"1e8483043efd043aee8c0e4fb9a88cab\",\"expiry\":\"2024-07-30T15:08:18Z\"},\"host\":\"trustchain-backend.api.aws.stg.ldg-tech.com\",\"rp\":[{\"credential\":{\"version\":0,\"curveId\":33,\"signAlgorithm\":1,\"publicKey\":\"03cb7628e7248ddf9c07da54b979f16bf081fb3d173aac0992ad2a44ef6a388ae2\"},\"signature\":\"3045022100cfd0b41bfcb03eb67b9a45752503490381db58372644b919dd4a74ce0ef074c302201242ab3f44eac798b90c5ccdc118f8a173ca1af5bf3876ac2b4b5156ec136b6c\"}],\"protocolVersion\":{\"major\":1,\"minor\":0,\"patch\":0}},\"signature\":{\"credential\":{\"version\":0,\"curveId\":33,\"signAlgorithm\":1,\"publicKey\":\"039c29f2c2079658846f3006c7bc9bb606a62f8ca9ea3d3fa908c3b9ec245cd314\"},\"signature\":\"3045022100b53e240d7a2142335206a9242adf1cc921ff260913c5349c2d5406c644de4b9a022057ce34b4e868dfb4cecfd2a98c0908f9f3d76ce9796bee1cac8312708077c3b1\",\"attestation\":\"0242303065333939363566363335326365333538373438613663363338333136303363353937653162323336343937666164333865353938346639643437386562336337\"}}"
},
Expand All @@ -284,7 +294,8 @@
"headers": {
"accept": "application/json, text/plain, */*",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
}
},
"response": {
Expand All @@ -311,7 +322,8 @@
"content-length": "984",
"content-type": "application/json",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
},
"body": "{\"challenge\":{\"version\":0,\"challenge\":{\"data\":\"4f9f449933513aaa4c7e2a34680d311b\",\"expiry\":\"2024-07-30T15:08:18Z\"},\"host\":\"trustchain-backend.api.aws.stg.ldg-tech.com\",\"rp\":[{\"credential\":{\"version\":0,\"curveId\":33,\"signAlgorithm\":1,\"publicKey\":\"03cb7628e7248ddf9c07da54b979f16bf081fb3d173aac0992ad2a44ef6a388ae2\"},\"signature\":\"3045022100edbc63e05a574172e00d74a26e36d34d7c13e5e61525bfeb2395f217c70c82f2022077632a0062ab556ec9d74434ca075ca11a61a34bae5107804f65c0f56883d69d\"}],\"protocolVersion\":{\"major\":1,\"minor\":0,\"patch\":0}},\"signature\":{\"credential\":{\"version\":0,\"curveId\":33,\"signAlgorithm\":1,\"publicKey\":\"03843c26fa5c75f465586722218a6e81fe96d50b3ef73d787e52cf432264c5adf1\"},\"signature\":\"304402201eef8d8815cf11cf3babf78c7c82584234232eb2ede3afe404986ab1f4a6f902022008f5fee808cc2b4ef5fd5374e46f6c82b8243e7da1c6aca3f2655edde40d51ce\",\"attestation\":\"0242303065333939363566363335326365333538373438613663363338333136303363353937653162323336343937666164333865353938346639643437386562336337\"}}"
},
Expand All @@ -338,7 +350,8 @@
"accept": "application/json, text/plain, */*",
"authorization": "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NiJ9.eyJpc3MiOiJ0cnVzdGNoYWluLWJhY2tlbmQuYXBpLmF3cy5zdGcubGRnLXRlY2guY29tIiwic3ViIjoiMDM4NDNjMjZmYTVjNzVmNDY1NTg2NzIyMjE4YTZlODFmZTk2ZDUwYjNlZjczZDc4N2U1MmNmNDMyMjY0YzVhZGYxIiwiYXVkIjpbIkNsb3VkU3luYyIsInRydXN0Y2hhaW4iXSwiZXhwIjoxNzIyMzUwNTk4LCJpYXQiOjE3MjIzNTAyOTcsImp0aSI6IjFkOTI1NmFjLTk5MDktNGQyZi04ZWNjLTdmNjQ3Zjk5ZjNlYSIsInBlcm1pc3Npb25zIjp7IjAwZTM5OTY1ZjYzNTJjZTM1ODc0OGE2YzYzODMxNjAzYzU5N2UxYjIzNjQ5N2ZhZDM4ZTU5ODRmOWQ0NzhlYjNjNyI6eyJtLzAnLzE2Jy8wJyI6WyJvd25lciJdfX0sImRldmljZSI6ZmFsc2UsInJlZnJlc2hFeHBpcmF0aW9uIjoiMjAyNC0wNy0zMFQxNTozODoxOFoifQ.FlfJfH0i794gP_vJOB7Xdy4-xlxmLoAoYhFp5NFFqvWp0bvkpsUbx_GEHvyXrBDP87fQEem1JzENMEMfS4Id_g",
"host": "trustchain-backend.api.aws.stg.ldg-tech.com",
"user-agent": "axios/0.26.1"
"accept-encoding": "gzip, compress, deflate, br",
"user-agent": "axios/1.7.3"
}
},
"response": {
Expand Down
Loading

0 comments on commit 8f4ef5a

Please sign in to comment.