mirror of
https://github.com/aljazceru/ark.git
synced 2025-12-17 20:24:21 +01:00
Add tests for adversarial scenarios (#300)
* fix and test cheating scenario (malicious double spend) * test and fix async vtxo cheating cases * add replace statement in go.mod * Update server/internal/core/application/covenantless.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * Update server/internal/infrastructure/wallet/btc-embedded/psbt.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * Update server/test/e2e/covenant/e2e_test.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * Update server/test/e2e/covenantless/e2e_test.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * Update server/test/e2e/covenantless/e2e_test.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * remove unused * [btc-embedded] fix GetNotificationChannel * [tx-builder] fix redeem transaction fee estimator * close grpc client in tests * [application] rework listentoscannerNotification * [application][covenant] fix getConnectorAmount * [tx-builder][covenant] get connector amount from wallet * e2e test sleep time * [liquid-standalone] ListConnectorUtxos: filter by script client side * fix Makefile integrationtest * do not use cache in integration tests * use VtxoKey as argument of findForfeitTxBitcoin * wrap adversarial test in t.Run * increaste test timeout * CI: setup go 1.23.1 * CI: revert go version * add replace in server/go.mod * Update server/internal/core/application/covenant.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * remove replace * readd replace statement * fixes * go work sync * fix CI --------- Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>
This commit is contained in:
@@ -15,7 +15,7 @@ type ArkClient interface {
|
||||
Unlock(ctx context.Context, password string) error
|
||||
Lock(ctx context.Context, password string) error
|
||||
Balance(ctx context.Context, computeExpiryDetails bool) (*Balance, error)
|
||||
Receive(ctx context.Context) (string, string, error)
|
||||
Receive(ctx context.Context) (offchainAddr, boardingAddr string, err error)
|
||||
SendOnChain(ctx context.Context, receivers []Receiver) (string, error)
|
||||
SendOffChain(
|
||||
ctx context.Context, withExpiryCoinselect bool, receivers []Receiver,
|
||||
@@ -26,7 +26,7 @@ type ArkClient interface {
|
||||
) (string, error)
|
||||
SendAsync(ctx context.Context, withExpiryCoinselect bool, receivers []Receiver) (string, error)
|
||||
Claim(ctx context.Context) (string, error)
|
||||
ListVtxos(ctx context.Context) ([]client.Vtxo, []client.Vtxo, error)
|
||||
ListVtxos(ctx context.Context) (spendable, spent []client.Vtxo, err error)
|
||||
GetTransactionHistory(ctx context.Context) ([]Transaction, error)
|
||||
Dump(ctx context.Context) (seed string, err error)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user