Skip to content

Commit b930e2b

Browse files
author
diogorac
committed
uncomment tests
1 parent 88ac906 commit b930e2b

File tree

1 file changed

+3
-22
lines changed

1 file changed

+3
-22
lines changed

tests/test_sig.c

Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -111,31 +111,12 @@ void test_bigchain_build_json_tx(void) {
111111
TEST_ASSERT_EQUAL(0, memcmp(tx.id, transaction_id, 64));
112112

113113
}
114-
void test_bigchain_build_json_tx2(void) {
115-
BIGCHAIN_TX tx;
116-
117-
char json[800] = {0};
118-
memcpy(json, tx_json, strlen(tx_json));
119-
120-
memset(&tx, 0, sizeof(BIGCHAIN_TX));
121-
prepare_tx(&tx);
122-
// bigchain_build_json_tx(&tx, json);
123-
124-
char sig[128] = {0};
125-
bigchain_sign_transaction((uint8_t*)json, strlen(json), (uint8_t*)privkey, (uint8_t*)pubkey, (uint8_t*)sig);
126-
bigchain_fulfill_and_serialize(&tx, (uint8_t*)json, 800, (uint8_t*)sig, (uint8_t*)pubkey);
127-
uint8_t transaction_id[] = {0xeb,0x39,0x0d,0x15,0x7b,0xc9,0x8d,0xba,0x07,0x26,0x46,0x31,0x11,0xc7,0x31,0x9a,0x28,0x13,0x2d,0x62,0x3b,0x29,0x7b,0x97,0xa9,0x1c,0x96,0x1d,0x1a,0xe1,0xe9,0x07};
128-
129-
// TEST_ASSERT_EQUAL(0, memcmp(tx.inputs->fulfillment, fullfil, 137));
130-
TEST_ASSERT_EQUAL(0, memcmp(tx.id, transaction_id, 32));
131-
}
132114

133115
int main(void) {
134116
UNITY_BEGIN();
135-
// RUN_TEST(test_sig);
136-
// RUN_TEST(test_bigchain_build_json_inputs);
137-
// RUN_TEST(test_bigchain_build_json_outputs);
117+
RUN_TEST(test_sig);
118+
RUN_TEST(test_bigchain_build_json_inputs);
119+
RUN_TEST(test_bigchain_build_json_outputs);
138120
RUN_TEST(test_bigchain_build_json_tx);
139-
// RUN_TEST(test_bigchain_build_json_tx2);
140121
return UNITY_END();
141122
}

0 commit comments

Comments
 (0)