You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
stbx-service-rest: Create and enable integration tests #271 (#277)
* stbx-service-rest: Create and enable client-server integration tests. #271
* stbx-service-rest: Fix permissions on CI test suite. #271
* stbx-service-rest: Create PureScript test suite for tx API POSTs and GETs. #271
* Chain tests with && so one failure will fail the whole suite. #271
* Make sure projects in test suite are built before they are tested. #271
* stbx-service-rest: Add index-test.js test runner. #271
-- first we post our example transactions to the API
30
+
postExampleTransactionsSpec
31
+
32
+
-- then we try to read them back in
33
+
getExampleTransactionsSpec
34
+
35
+
36
+
postExampleTransactionsSpec::SpecUnit
37
+
postExampleTransactionsSpec =
38
+
describe "Statebox transaction API HTTP service"do
39
+
it "should respond to POST <root tx> correctly"do
40
+
res <-Stbx.postTransactionHex endpointUrl "0a0022200a1e47756172616e746565642d456e7472616e63652d546f6b656e2e74657374"
41
+
let dump1 = spy "POST response: " res
42
+
todo
43
+
it "should respond to POST <wiring tx> correctly"do
44
+
res <-Stbx.postTransactionHex endpointUrl "0a20dce4021c8f117e89c479665f6d61ff650b150af375d6498b593da6afa8d2ca9f1afa010add010a0a70726976696c656467651001100010021000100210001006100010011000100310001003100010011000100210001004100010031000100510001004100010051000100110001005100010021000100510001006100010021000100610001003100010061000100510001000100310001a036275791a07666f7253616c651a05626c6f636b1a07756e626c6f636b1a047363616e1a086e6f74536f6c64321a0873686f774f7665721a076e6f74536f6c641a066e6f53686f771a04627579271a076275794261636b1a096e6f745265736f6c641a0663726561746512160a046d61696e10011801220a70726976696c656467651800"
45
+
let dump1 = spy "POST response: " res
46
+
todo
47
+
it "should respond to POST <0th firing tx (the 'execution')> correctly"do
48
+
res <-Stbx.postTransactionHex endpointUrl "0a20dce4021cacc5f351d54402799977d7e4f7b86805359aec724805c80ec0b4d546120710001a03aa0003"
49
+
let dump1 = spy "POST response: " res
50
+
todo
51
+
it "should respond to POST <1st firing tx> correctly"do
52
+
res <-Stbx.postTransactionHex endpointUrl "0a20dce4021c1447c0b50a5ce982dd4e78650ca3cc642004b4408eac0264da1ca5b812240a20dce4021c1447c0b50a5ce982dd4e78650ca3cc642004b4408eac0264da1ca5b81004"
53
+
let dump1 = spy "POST response: " res
54
+
todo
55
+
it "should respond to POST <2nd firing tx> correctly"do
56
+
res <-Stbx.postTransactionHex endpointUrl "0a20dce4021cd649d3a9d1f69832f26739c1d81c873ca5f343ec2dd92d335adfc805122a0a20dce4021c1447c0b50a5ce982dd4e78650ca3cc642004b4408eac0264da1ca5b810011a04111aaa11"
57
+
let dump1 = spy "POST response: " res
58
+
todo
59
+
it "should respond to POST <3rd firing tx> correctly"do
60
+
res <-Stbx.postTransactionHex endpointUrl "0a20dce4021c15fda2dfd9ec2ef4413b9e5a4ac5cbd8def33c0ca2c071f75a71464b122b0a20dce4021c1447c0b50a5ce982dd4e78650ca3cc642004b4408eac0264da1ca5b810051a05222bbbb222"
61
+
let dump1 = spy "POST response: " res
62
+
todo
63
+
64
+
getExampleTransactionsSpec::SpecUnit
65
+
getExampleTransactionsSpec =
66
+
describe "Statebox transaction API HTTP service"do
0 commit comments