code.vegaprotocol.io/vega@v0.79.0/core/integration/features/teams/0083-RFPR-061.feature (about) 1 Feature: Test allow lists, based on team_rewards.feature test in rewards set. 2 3 Background: 4 # Initialise the network 5 Given time is updated to "2023-01-01T00:00:00Z" 6 And the average block duration is "1" 7 And the following network parameters are set: 8 | name | value | 9 | market.fee.factors.makerFee | 0.001 | 10 | network.markPriceUpdateMaximumFrequency | 0s | 11 | market.auction.minimumDuration | 1 | 12 | validators.epoch.length | 60s | 13 | limits.markets.maxPeggedOrders | 4 | 14 | referralProgram.minStakedVegaTokens | 0 | 15 16 # Initialise the markets 17 And the following assets are registered: 18 | id | decimal places | quantum | 19 | USD-1-10 | 1 | 10 | 20 And the markets: 21 | id | quote name | asset | risk model | margin calculator | auction duration | fees | price monitoring | data source config | linear slippage factor | quadratic slippage factor | sla params | decimal places | position decimal places | 22 | ETH/USD-1-10 | ETH | USD-1-10 | default-log-normal-risk-model | default-margin-calculator | 1 | default-none | default-none | default-eth-for-future | 1e-3 | 0 | default-futures | 0 | 0 | 23 24 # Initialise the parties 25 Given the parties deposit on asset's general account the following amount: 26 | party | asset | amount | 27 | lpprov | USD-1-10 | 10000000000 | 28 | aux1 | USD-1-10 | 10000000 | 29 | aux2 | USD-1-10 | 10000000 | 30 | referrer1 | USD-1-10 | 10000000 | 31 | referrer2 | USD-1-10 | 10000000 | 32 | referrer3 | USD-1-10 | 10000000 | 33 | referee1 | USD-1-10 | 10000000 | 34 | referee2 | USD-1-10 | 10000000 | 35 | referee3 | USD-1-10 | 10000000 | 36 | another1 | USD-1-10 | 10000000 | 37 | another2 | USD-1-10 | 10000000 | 38 | a3c024b4e23230c89884a54a813b1ecb4cb0f827a38641c66eeca466da6b2ddf | USD-1-10 | 10000000 | 39 40 # Exit opening auctions 41 Given the parties submit the following liquidity provision: 42 | id | party | market id | commitment amount | fee | lp type | 43 | lp1 | lpprov | ETH/USD-1-10 | 1000000 | 0.01 | submission | 44 And the parties place the following pegged iceberg orders: 45 | party | market id | peak size | minimum visible size | side | pegged reference | volume | offset | 46 | lpprov | ETH/USD-1-10 | 5000 | 1000 | buy | BID | 10000 | 1 | 47 | lpprov | ETH/USD-1-10 | 5000 | 1000 | sell | ASK | 10000 | 1 | 48 When the parties place the following orders: 49 | party | market id | side | volume | price | resulting trades | type | tif | 50 | aux1 | ETH/USD-1-10 | buy | 1 | 990 | 0 | TYPE_LIMIT | TIF_GTC | 51 | aux1 | ETH/USD-1-10 | buy | 1 | 1000 | 0 | TYPE_LIMIT | TIF_GTC | 52 | aux2 | ETH/USD-1-10 | sell | 1 | 1000 | 0 | TYPE_LIMIT | TIF_GTC | 53 | aux2 | ETH/USD-1-10 | sell | 1 | 1100 | 0 | TYPE_LIMIT | TIF_GTC | 54 And the opening auction period ends for market "ETH/USD-1-10" 55 When the network moves ahead "1" blocks 56 And the trading mode should be "TRADING_MODE_CONTINUOUS" for the market "ETH/USD-1-10" 57 58 # Create the teams 59 Given the parties create the following referral codes: 60 | party | code | is_team | team | closed | allow list | 61 | referrer1 | referral-code-1 | true | team1 | true | referee1,another1 | 62 | referrer2 | referral-code-2 | true | team2 | false | | 63 | referrer3 | referral-code-3 | true | team3 | true | | 64 And the parties apply the following referral codes: 65 | party | code | is_team | team | 66 | referee1 | referral-code-1 | true | team1 | 67 | referee2 | referral-code-2 | true | team2 | 68 | referee3 | referral-code-2 | true | team2 | 69 And the team "team1" has the following members: 70 | party | 71 | referrer1 | 72 | referee1 | 73 And the team "team2" has the following members: 74 | party | 75 | referrer2 | 76 | referee2 | 77 | referee3 | 78 And the team "team3" has the following members: 79 | party | 80 | referrer3 | 81 82 @Closed 83 Scenario: 0083-RFPR-061 adding parties to non-closed team works as expected. 84 Given the parties submit the following recurring transfers: 85 | id | from | from_account_type | to | to_account_type | entity_scope | teams | ntop | asset | amount | start_epoch | end_epoch | factor | metric | metric_asset | markets | 86 | 1 | a3c024b4e23230c89884a54a813b1ecb4cb0f827a38641c66eeca466da6b2ddf | ACCOUNT_TYPE_GENERAL | 0000000000000000000000000000000000000000000000000000000000000000 | ACCOUNT_TYPE_REWARD_MAKER_PAID_FEES | TEAMS | team1,team2 | 1 | USD-1-10 | 10000 | 1 | | 1 | DISPATCH_METRIC_MAKER_FEES_PAID | USD-1-10 | ETH/USD-1-10 | 87 When the parties apply the following referral codes: 88 | party | code | is_team | team | 89 | another2 | referral-code-2 | true | team2 | 90 Then the team "team2" has the following members: 91 | party | 92 | referrer2 | 93 | referee2 | 94 | referee3 | 95 | another2 | 96 When the parties place the following orders: 97 | party | market id | side | volume | price | resulting trades | type | tif | 98 | aux1 | ETH/USD-1-10 | sell | 10 | 1000 | 0 | TYPE_LIMIT | TIF_GTC | 99 | referee1 | ETH/USD-1-10 | buy | 10 | 1000 | 1 | TYPE_LIMIT | TIF_GTC | 100 | aux1 | ETH/USD-1-10 | sell | 10 | 1000 | 0 | TYPE_LIMIT | TIF_GTC | 101 | referee2 | ETH/USD-1-10 | buy | 10 | 1000 | 1 | TYPE_LIMIT | TIF_GTC | 102 | aux1 | ETH/USD-1-10 | sell | 5 | 1000 | 0 | TYPE_LIMIT | TIF_GTC | 103 | referee3 | ETH/USD-1-10 | buy | 5 | 1000 | 1 | TYPE_LIMIT | TIF_GTC | 104 When the network moves ahead "1" epochs 105 Then "referee1" should have vesting account balance of "5714" for asset "USD-1-10" 106 And "referee2" should have vesting account balance of "2142" for asset "USD-1-10" 107 And "referee3" should have vesting account balance of "2142" for asset "USD-1-10"