Skip to content

Commit

Permalink
added
Browse files Browse the repository at this point in the history
  • Loading branch information
stackman27 committed Dec 11, 2023
1 parent 500a4db commit 5507ac9
Show file tree
Hide file tree
Showing 6 changed files with 41 additions and 3 deletions.
1 change: 1 addition & 0 deletions .github/workflows/on-demand-ocr-soak-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ on:
- "KROMA_SEPOLIA"
- "WEMIX_TESTNET"
- "WEMIX_MAINNET"
- "BTTC_TESTNET"
fundingPrivateKey:
description: Private funding key (Skip for Simulated)
required: false
Expand Down
5 changes: 3 additions & 2 deletions common/config/chaintype.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,17 @@ const (
ChainWeMix ChainType = "wemix"
ChainKroma ChainType = "kroma"
ChainZkSync ChainType = "zksync"
ChainBttc ChainType = "bttc"
)

var ErrInvalidChainType = fmt.Errorf("must be one of %s or omitted", strings.Join([]string{
string(ChainArbitrum), string(ChainMetis), string(ChainXDai), string(ChainOptimismBedrock), string(ChainCelo),
string(ChainKroma), string(ChainWeMix), string(ChainZkSync)}, ", "))
string(ChainKroma), string(ChainWeMix), string(ChainZkSync), string(ChainBttc)}, ", "))

// IsValid returns true if the ChainType value is known or empty.
func (c ChainType) IsValid() bool {
switch c {
case "", ChainArbitrum, ChainMetis, ChainOptimismBedrock, ChainXDai, ChainCelo, ChainKroma, ChainWeMix, ChainZkSync:
case "", ChainArbitrum, ChainMetis, ChainOptimismBedrock, ChainXDai, ChainCelo, ChainKroma, ChainWeMix, ChainZkSync, ChainBttc:
return true
}
return false
Expand Down
28 changes: 28 additions & 0 deletions core/chains/evm/config/toml/defaults/Bttc_testnet.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
ChainID = '1029'
FinalityDepth = 9000
# blocks are generated every 2-4s
LogPollInterval = '2s'
# Blocks are only emitted when a transaction happens / no empty blocks
NoNewHeadsThreshold = '0'

[GasEstimator]
EIP1559DynamicFees = false


[GasEstimator.BlockHistory]
# how many blocks we want to keep in memory to calculate gas price
# # Average block time of 2s
BlockHistorySize = 24

[Transactions]
ResendAfterThreshold = '30s'

[HeadTracker]
# re-org for bttc is really high so we want to check for the block where reorg happens
HistoryDepth = 500

[NodePool]
SyncThreshold = 10

[OCR]
ContractConfirmations = 1
6 changes: 6 additions & 0 deletions integration-tests/contracts/contract_deployer.go
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,8 @@ func NewContractDeployer(bcClient blockchain.EVMClient, logger zerolog.Logger) (
return &KromaContractDeployer{NewEthereumContractDeployer(clientImpl, logger)}, nil
case *blockchain.WeMixClient:
return &WeMixContractDeployer{NewEthereumContractDeployer(clientImpl, logger)}, nil
case *blockchain.BttcClient:
return &BttcContractDeployer{NewEthereumContractDeployer(clientImpl, logger)}, nil
}
return nil, errors.New("unknown blockchain client implementation for contract deployer, register blockchain client in NewContractDeployer")
}
Expand Down Expand Up @@ -256,6 +258,10 @@ type WeMixContractDeployer struct {
*EthereumContractDeployer
}

type BttcContractDeployer struct {
*EthereumContractDeployer
}

// NewEthereumContractDeployer returns an instantiated instance of the ETH contract deployer
func NewEthereumContractDeployer(ethClient blockchain.EVMClient, logger zerolog.Logger) *EthereumContractDeployer {
return &EthereumContractDeployer{
Expand Down
2 changes: 1 addition & 1 deletion integration-tests/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ require (
github.com/slack-go/slack v0.12.2
github.com/smartcontractkit/chainlink-automation v1.0.1
github.com/smartcontractkit/chainlink-common v0.1.7-0.20231206181640-faad3f11cfad
github.com/smartcontractkit/chainlink-testing-framework v1.21.0
github.com/smartcontractkit/chainlink-testing-framework v1.22.1-0.20231211214733-01e7b517d5a6
github.com/smartcontractkit/chainlink-vrf v0.0.0-20231120191722-fef03814f868
github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000
github.com/smartcontractkit/libocr v0.0.0-20231130143053-c5102a9c0fb7
Expand Down
2 changes: 2 additions & 0 deletions integration-tests/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -1534,6 +1534,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202312
github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20231205180940-ea2e3e916725/go.mod h1:vHrPBipRL52NdPp77KXNU2k1IoCUa1B33N9otZQPYko=
github.com/smartcontractkit/chainlink-testing-framework v1.21.0 h1:MrtpGMgPpcRX06FtDEj14Vokoo6Sx8e0/D6AA9LxCgM=
github.com/smartcontractkit/chainlink-testing-framework v1.21.0/go.mod h1:9SCqZ+lcWZNEofpPgasQ+wUF6A6fFgZvWmhqQJwFYV0=
github.com/smartcontractkit/chainlink-testing-framework v1.22.1-0.20231211214733-01e7b517d5a6 h1:pAJ4ogR1OQSwmVMmUtMAEOLH5N4wIOEdwL/izuJj6v0=
github.com/smartcontractkit/chainlink-testing-framework v1.22.1-0.20231211214733-01e7b517d5a6/go.mod h1:yu6qqrppNJfutQV37fiSs4eS0uQP5QT0ebi3tlIgWN0=
github.com/smartcontractkit/chainlink-vrf v0.0.0-20231120191722-fef03814f868 h1:FFdvEzlYwcuVHkdZ8YnZR/XomeMGbz5E2F2HZI3I3w8=
github.com/smartcontractkit/chainlink-vrf v0.0.0-20231120191722-fef03814f868/go.mod h1:Kn1Hape05UzFZ7bOUnm3GVsHzP0TNrVmpfXYNHdqGGs=
github.com/smartcontractkit/go-plugin v0.0.0-20231003134350-e49dad63b306 h1:ko88+ZznniNJZbZPWAvHQU8SwKAdHngdDZ+pvVgB5ss=
Expand Down

0 comments on commit 5507ac9

Please sign in to comment.