Files
ark/pkg/client-sdk/Makefile
Dusan Sekulic d184fc0f41 [SDK] E2E test for WASM wrapper (#378)
* wasm e2e test

* Remove ark-sdk.wasm.gz from repository

* pr review

* exclude test files from linting

* fix

* test fix

* go work sync

* gha fix

* gha fix

* wasm e2e test

* kill webserver

* Fix nonce encoding/decoding & Fix pop from queue of payment requests (#375)

* bug fix - paymentMap pop input traversal

* bug fix - nonce encode/decode

* pr review

* pr review

* Fix trivy gh action (#381)

* Update trivy gha

* Update tryvy gha

* Fix

* merge

* Panic recovery in app svc (#372)

* panic recovery

* pr review

* Support connecting to bitcoind via ZMQ (#286)

* add ZMQ env vars

* consolidate config and app-config naming

* [Server] Validate forfeit txs without re-building them (#382)

* compute forfeit partial tx client-side first

* fix conflict

* go work sync

* move verify sig in VerifyForfeits

* move check after len(inputs)

* Hotfix: Prevent ZMQ-based bitcoin wallet to panic  (#383)

* Hotfix bct embedded wallet w/ ZMQ

* Fixes

* Rename vtxo is_oor to is_pending (#385)

* Rename vtxo is_oor > is_pending

* Clean swaggers

* Change representation of taproot trees & Internal fixes (#384)

* migrate descriptors --> tapscripts

* fix covenantless

* dynamic boarding exit delay

* remove duplicates in tree and bitcointree

* agnostic signatures validation

* revert GetInfo change

* renaming VtxoScript var

* Agnostic script server (#6)

* Hotfix: Prevent ZMQ-based bitcoin wallet to panic  (#383)

* Hotfix bct embedded wallet w/ ZMQ

* Fixes

* Rename vtxo is_oor to is_pending (#385)

* Rename vtxo is_oor > is_pending

* Clean swaggers

* Revert changes to client and sdk

* descriptor in oneof

* support CHECKSIG_ADD in MultisigClosure

* use right witness size in OOR tx fee estimation

* Revert changes

---------

Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>

* fix unit test

* fix unit test

* fix unit test

---------

Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>
Co-authored-by: Marco Argentieri <3596602+tiero@users.noreply.github.com>
Co-authored-by: Louis Singer <41042567+louisinger@users.noreply.github.com>
2024-11-22 15:31:20 +01:00

45 lines
1.4 KiB
Makefile
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

.PHONY: genrest test vet lint prepare-wasm-test
## genrest: compiles rest client from stub with https://github.com/go-swagger/go-swagger
genrest:
@echo "Generating rest client from stub..."
@swagger generate client -f ../../api-spec/openapi/swagger/ark/v1/service.swagger.json -t ./client/rest/service --client-package=arkservice
## test: runs unit tests
test:
@echo "Running unit tests..."
@go test -v -count=1 -race $$(go list ./... | grep -v '/test/wasm')
## vet: code analysis
vet:
@echo "Running code analysis..."
@go vet ./...
## lint: lint codebase
lint:
@echo "Linting code..."
@golangci-lint run --fix --verbose
## wasm: compiles the client-sdk to wasm
WASM_DIR = wasm
BUILD_DIR = build
VERSION := $(shell git describe --tags --always --dirty)
GO_VERSION := $(shell go version | cut -d' ' -f3)
.PHONY: build-wasm
build-wasm:
@mkdir -p $(BUILD_DIR)
@echo "Version: $(VERSION)"
@GOOS=js GOARCH=wasm GO111MODULE=on go build -ldflags="-s -w -X 'main.Version=$(VERSION)'" -o $(BUILD_DIR)/ark-sdk.wasm $(WASM_DIR)/main.go
test-wasm:
$(MAKE) build-wasm BUILD_DIR=./test/wasm/web
@echo "Copying $(go env GOROOT)/misc/wasm/wasm_exec.js"
@cp `go env GOROOT`/misc/wasm/wasm_exec.js ./test/wasm/web
@echo "Starting web server..."
@cd ./test/wasm/web && python3 -m http.server 8000 &
@echo "Waiting for server to start..."
@sleep 3
@echo "Running tests..."
@cd ./test/wasm && go test -v