difftreelog
Merge branch 'develop' into feature/multi-assets-redone
in: master
12 files changed
.github/workflows/ci-master.ymldiffbeforeafterboth18 uses: ./.github/workflows/node-only-update_v2.yml18 uses: ./.github/workflows/node-only-update_v2.yml191920 forkless:20 forkless:21 if: ${{ contains( github.event.pull_request.labels.*.name, 'forkless') }}22 uses: ./.github/workflows/forkless.yml21 uses: ./.github/workflows/forkless.yml232224 canary:23 canary:25 if: ${{ contains( github.event.pull_request.labels.*.name, 'canary') }}26 uses: ./.github/workflows/canary.yml24 uses: ./.github/workflows/canary.yml27 secrets: inherit # pass all secrets25 secrets: inherit # pass all secrets282629 xcm:27 xcm:30 if: ${{ contains( github.event.pull_request.labels.*.name, 'xcm') }}31 uses: ./.github/workflows/xcm.yml28 uses: ./.github/workflows/xcm.yml32 secrets: inherit # pass all secrets29 secrets: inherit # pass all secrets3330.github/workflows/market-test.ymldiffbeforeafterbothno changes
.github/workflows/market-test_v2.ymldiffbeforeafterboth45 repository: 'UniqueNetwork/market-e2e-tests'45 repository: 'UniqueNetwork/market-e2e-tests'46 ssh-key: ${{ secrets.GH_PAT }}46 ssh-key: ${{ secrets.GH_PAT }}47 path: 'qa-tests'47 path: 'qa-tests'48 ref: 'ci_test_v2'48 ref: 'master'494950 - name: Read .env file50 - name: Read .env file51 uses: xom9ikk/dotenv@v1.0.251 uses: xom9ikk/dotenv@v1.0.2.github/workflows/node-only-update_v2.ymldiffbeforeafterboth10# A workflow run is made up of one or more jobs that can run sequentially or in parallel10# A workflow run is made up of one or more jobs that can run sequentially or in parallel11jobs:11jobs:121213 execution-marix:13 nodes-execution-matrix:141415 name: execution matrix15 name: execution matrix161642424343444445 forkless-update-nodata:45 nodes-only-update:46 needs: execution-marix46 needs: nodes-execution-matrix47 # The type of runner that the job will run on47 # The type of runner that the job will run on48 runs-on: [self-hosted-ci,large]48 runs-on: [self-hosted-ci,large]4949575758 strategy:58 strategy:59 matrix:59 matrix:60 include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}60 include: ${{fromJson(needs.nodes-execution-matrix.outputs.matrix)}}616162 steps:62 steps:6363156 exit 0156 exit 0157 shell: bash157 shell: bash158159 - name: Checkout at '${{ matrix.mainnet_branch }}' branch160 uses: actions/checkout@master161 with:162 ref: ${{ matrix.mainnet_branch }} #Checking out head commit163 path: ${{ matrix.mainnet_branch }}164158165159 - name: Run tests before Node Parachain upgrade166 - name: Run tests before Node Parachain upgrade160 working-directory: tests167 working-directory: ${{ matrix.mainnet_branch }}/tests161 run: |168 run: |162 yarn install169 yarn install163 yarn add mochawesome170 yarn add mochawesome164 node scripts/readyness.js171 echo "Ready to start tests"165 echo "Ready to start tests"172 yarn polkadot-types166 yarn polkadot-types173 NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}167 NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}168 env:174 env:169 RPC_URL: http://127.0.0.1:9933/175 RPC_URL: http://127.0.0.1:9933/170176174 if: success() || failure() # run this step even if previous step failed180 if: success() || failure() # run this step even if previous step failed175 with:181 with:176 name: Tests before node upgrade ${{ matrix.network }} # Name of the check run which will be created182 name: Tests before node upgrade ${{ matrix.network }} # Name of the check run which will be created177 path: tests/mochawesome-report/test-*.json # Path to test results183 path: ${{ matrix.mainnet_branch }}/tests/mochawesome-report/test-*.json # Path to test results178 reporter: mochawesome-json184 reporter: mochawesome-json179 fail-on-error: 'false'185 fail-on-error: 'false'180186262268263 - name: Remove builder cache269 - name: Remove builder cache264 if: always() # run this step always270 if: always() # run this step always265 run: |271 run: |266 docker builder prune -f272 docker builder prune -f -a267 docker system prune -f273 docker system prune -f274 docker image prune -f -a268275269 - name: Clean Workspace276 - name: Clean Workspace270 if: always()277 if: always()Cargo.lockdiffbeforeafterboth660066006601[[package]]6601[[package]]6602name = "pallet-unique"6602name = "pallet-unique"6603version = "0.1.4"6603version = "0.2.0"6604dependencies = [6604dependencies = [6605 "ethereum",6605 "ethereum",6606 "evm-coder",6606 "evm-coder",pallets/app-promotion/src/lib.rsdiffbeforeafterboth589 let flush_stake = || -> DispatchResult {589 let flush_stake = || -> DispatchResult {590 if let Some(last_id) = &*last_id.borrow() {590 if let Some(last_id) = &*last_id.borrow() {591 if !income_acc.borrow().is_zero() {591 if !income_acc.borrow().is_zero() {592 <T::Currency as Currency<T::AccountId>>::transfer(592 <T::Currency as Currency<T::AccountId>>::transfer(593 &T::TreasuryAccountId::get(),593 &T::TreasuryAccountId::get(),594 last_id,594 last_id,595 *income_acc.borrow(),595 *income_acc.borrow(),596 ExistenceRequirement::KeepAlive,596 ExistenceRequirement::KeepAlive,597 )597 )?;598 .and_then(|_| {598599 Self::add_lock_balance(last_id, *income_acc.borrow())?;599 Self::add_lock_balance(last_id, *income_acc.borrow())?;600 <TotalStaked<T>>::try_mutate(|staked| {600 <TotalStaked<T>>::try_mutate(|staked| -> DispatchResult {601 staked601 *staked = staked602 .checked_add(&*income_acc.borrow())602 .checked_add(&*income_acc.borrow())603 .ok_or(ArithmeticError::Overflow.into())603 .ok_or(ArithmeticError::Overflow)?;604 Ok(())604 })605 })?;605 })?;606606607 Self::deposit_event(Event::StakingRecalculation(607 Self::deposit_event(Event::StakingRecalculation(608 last_id.clone(),608 last_id.clone(),runtime/common/mod.rsdiffbeforeafterboth828283pub type SignedExtra = (83pub type SignedExtra = (84 frame_system::CheckSpecVersion<Runtime>,84 frame_system::CheckSpecVersion<Runtime>,85 // system::CheckTxVersion<Runtime>,85 frame_system::CheckTxVersion<Runtime>,86 frame_system::CheckGenesis<Runtime>,86 frame_system::CheckGenesis<Runtime>,87 frame_system::CheckEra<Runtime>,87 frame_system::CheckEra<Runtime>,88 frame_system::CheckNonce<Runtime>,88 frame_system::CheckNonce<Runtime>,runtime/opal/src/lib.rsdiffbeforeafterboth50 spec_name: create_runtime_str!(RUNTIME_NAME),50 spec_name: create_runtime_str!(RUNTIME_NAME),51 impl_name: create_runtime_str!(RUNTIME_NAME),51 impl_name: create_runtime_str!(RUNTIME_NAME),52 authoring_version: 1,52 authoring_version: 1,53 spec_version: 927020,53 spec_version: 927030,54 impl_version: 0,54 impl_version: 0,55 apis: RUNTIME_API_VERSIONS,55 apis: RUNTIME_API_VERSIONS,56 transaction_version: 2,56 transaction_version: 2,runtime/quartz/src/lib.rsdiffbeforeafterboth50 spec_name: create_runtime_str!(RUNTIME_NAME),50 spec_name: create_runtime_str!(RUNTIME_NAME),51 impl_name: create_runtime_str!(RUNTIME_NAME),51 impl_name: create_runtime_str!(RUNTIME_NAME),52 authoring_version: 1,52 authoring_version: 1,53 spec_version: 927020,53 spec_version: 927030,54 impl_version: 0,54 impl_version: 0,55 apis: RUNTIME_API_VERSIONS,55 apis: RUNTIME_API_VERSIONS,56 transaction_version: 2,56 transaction_version: 2,runtime/unique/src/lib.rsdiffbeforeafterboth50 spec_name: create_runtime_str!(RUNTIME_NAME),50 spec_name: create_runtime_str!(RUNTIME_NAME),51 impl_name: create_runtime_str!(RUNTIME_NAME),51 impl_name: create_runtime_str!(RUNTIME_NAME),52 authoring_version: 1,52 authoring_version: 1,53 spec_version: 927020,53 spec_version: 927030,54 impl_version: 0,54 impl_version: 0,55 apis: RUNTIME_API_VERSIONS,55 apis: RUNTIME_API_VERSIONS,56 transaction_version: 2,56 transaction_version: 2,tests/src/app-promotion.test.tsdiffbeforeafterboth661 });661 });662 });662 });663664 it('should increase total staked', async() => {665 await usingPlaygrounds(async (helper) => {666 const staker = accounts.pop()!;667 const totalStakedBefore = await helper.staking.getTotalStaked();668 await helper.staking.stake(staker, 100n * nominal);669670 // Wait for rewards and pay671 const stakedInBlock = (await helper.staking.getTotalStakedPerBlock({Substrate: staker.address}))[0][0];672 await helper.wait.forRelayBlockNumber(rewardAvailableInBlock(stakedInBlock));673 await helper.signTransaction(palletAdmin, helper.api!.tx.appPromotion.payoutStakers(100));674675 const totalStakedAfter = await helper.staking.getTotalStaked();676 expect(totalStakedAfter >= totalStakedBefore + calculateIncome(100n * nominal, 10n)).to.be.true;677678 // staker can unstake679 await helper.staking.unstake(staker);680 expect(await helper.staking.getTotalStaked()).to.be.equal(totalStakedAfter - calculateIncome(100n * nominal, 10n));681 });682 });663683664 it('should credit 0.05% for staking period', async () => { 684 it('should credit 0.05% for staking period', async () => { 665 await usingPlaygrounds(async helper => {685 await usingPlaygrounds(async helper => {tests/src/tx-version-presence.test.tsdiffbeforeafterbothno changes