@@ -409,7 +409,7 @@ Test( oracle, upd_price ) {
409
409
.data_len = sizeof ( idata ),
410
410
.program_id = & p_id
411
411
};
412
- cr_assert ( SUCCESS == dispatch ( & prm , acc ) );
412
+ cr_assert ( SUCCESSFULLY_UPDATED_AGGREGATE == dispatch ( & prm , acc ) );
413
413
cr_assert ( sptr -> comp_ [0 ].latest_ .price_ == 42L );
414
414
cr_assert ( sptr -> comp_ [0 ].latest_ .conf_ == 2L );
415
415
cr_assert ( sptr -> comp_ [0 ].latest_ .pub_slot_ == 1 );
@@ -426,7 +426,7 @@ Test( oracle, upd_price ) {
426
426
idata .price_ = 81 ;
427
427
idata .pub_slot_ = 2 ;
428
428
cvar .slot_ = 3 ;
429
- cr_assert ( SUCCESS == dispatch ( & prm , acc ) );
429
+ cr_assert ( SUCCESSFULLY_UPDATED_AGGREGATE == dispatch ( & prm , acc ) );
430
430
cr_assert ( sptr -> comp_ [0 ].latest_ .price_ == 81L );
431
431
cr_assert ( sptr -> comp_ [0 ].agg_ .price_ == 42L );
432
432
cr_assert ( sptr -> comp_ [0 ].latest_ .pub_slot_ == 2 );
@@ -436,7 +436,7 @@ Test( oracle, upd_price ) {
436
436
// next price doesnt change but slot does
437
437
cvar .slot_ = 4 ;
438
438
idata .pub_slot_ = 3 ;
439
- cr_assert ( SUCCESS == dispatch ( & prm , acc ) );
439
+ cr_assert ( SUCCESSFULLY_UPDATED_AGGREGATE == dispatch ( & prm , acc ) );
440
440
cr_assert ( sptr -> comp_ [0 ].latest_ .price_ == 81L );
441
441
cr_assert ( sptr -> comp_ [0 ].agg_ .price_ == 81L );
442
442
cr_assert ( sptr -> comp_ [0 ].latest_ .pub_slot_ == 3 );
@@ -446,7 +446,7 @@ Test( oracle, upd_price ) {
446
446
// next price doesnt change and neither does aggregate but slot does
447
447
idata .pub_slot_ = 4 ;
448
448
cvar .slot_ = 5 ;
449
- cr_assert ( SUCCESS == dispatch ( & prm , acc ) );
449
+ cr_assert ( SUCCESSFULLY_UPDATED_AGGREGATE == dispatch ( & prm , acc ) );
450
450
cr_assert ( sptr -> comp_ [0 ].latest_ .price_ == 81L );
451
451
cr_assert ( sptr -> comp_ [0 ].agg_ .price_ == 81L );
452
452
cr_assert ( sptr -> comp_ [0 ].latest_ .pub_slot_ == 4 );
@@ -466,7 +466,7 @@ Test( oracle, upd_price ) {
466
466
cvar .slot_ = 6 ;
467
467
idata .price_ = 50 ;
468
468
idata .conf_ = 6 ;
469
- cr_assert ( SUCCESS == dispatch ( & prm , acc ) );
469
+ cr_assert ( SUCCESSFULLY_UPDATED_AGGREGATE == dispatch ( & prm , acc ) );
470
470
cr_assert ( sptr -> comp_ [0 ].latest_ .price_ == 50L );
471
471
cr_assert ( sptr -> comp_ [0 ].latest_ .conf_ == 6L );
472
472
cr_assert ( sptr -> comp_ [0 ].latest_ .status_ == PC_STATUS_UNKNOWN );
@@ -478,7 +478,7 @@ Test( oracle, upd_price ) {
478
478
// Crank one more time and aggregate should be unknown
479
479
idata .pub_slot_ = 6 ;
480
480
cvar .slot_ = 7 ;
481
- cr_assert ( SUCCESS == dispatch ( & prm , acc ) );
481
+ cr_assert ( SUCCESSFULLY_UPDATED_AGGREGATE == dispatch ( & prm , acc ) );
482
482
cr_assert ( sptr -> agg_ .status_ == PC_STATUS_UNKNOWN );
483
483
}
484
484
@@ -559,7 +559,7 @@ Test( oracle, upd_price_no_fail_on_error ) {
559
559
pc_pub_key_assign ( & sptr -> comp_ [0 ].pub_ , (pc_pub_key_t * )& pkey );
560
560
561
561
// The update should now succeed, and have an effect.
562
- cr_assert ( SUCCESS == dispatch ( & prm , acc ) );
562
+ cr_assert ( SUCCESSFULLY_UPDATED_AGGREGATE == dispatch ( & prm , acc ) );
563
563
cr_assert ( sptr -> comp_ [0 ].latest_ .price_ == 42L );
564
564
cr_assert ( sptr -> comp_ [0 ].latest_ .conf_ == 9L );
565
565
cr_assert ( sptr -> comp_ [0 ].latest_ .pub_slot_ == 1 );
0 commit comments