Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add ci (without cypress) #125

Merged
merged 5 commits into from
May 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: CI

on:
pull_request:
branches:
- 'main'
workflow_dispatch:
jobs:
ci:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Use Node 16
uses: actions/setup-node@v2
with:
node-version: '16'

- name: Install dependencies
run: yarn install --frozen-lockfile

- name: run lint
run: npm run lint

- name: run prettier
run: npm run prettier

- name: unit test
run: npm run test:unit
49 changes: 49 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: "CodeQL"

on:
push:
branches: [main, ]
pull_request:
# The branches below must be a subset of the branches above
branches: [main]
schedule:
- cron: '0 9 * * 6'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth: 2

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
# Override language selection by uncommenting this and choosing your languages
# with:
# languages: go, javascript, csharp, python, cpp, java

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"dependencies": {
"@fortawesome/fontawesome-free": "^5.15.4",
"@mdi/font": "5.9.55",
"@rsksmart/rlogin": "^1.3.1-beta.2",
"@rsksmart/rlogin": "^1.3.3",
"@walletconnect/web3-provider": "^1.4.1",
"bignumber.js": "^9.0.1",
"bootstrap": "4.6.0",
Expand Down
2 changes: 1 addition & 1 deletion src/components/crossForm/CrossForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ export default {
async handleSwitchNetwork() {
this.switchNetwork = true
try {
this.selectedToken = {};
this.selectedToken = {}
this.willReceiveToken = null
const chainId = numToHex(this.sharedState.currentConfig.crossToNetwork.networkId)
await window.ethereum.request({
Expand Down
1 change: 0 additions & 1 deletion tests/unit/TransactionRowMixin.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ describe('TransactionRowMixin.js Test', () => {
expect(transactionRowMixin.vm.formattedReceiverAddress).toBe('0x2024...f15961')
expect(transactionRowMixin.vm.latestBlock).toBe(RSK_BLOCK_NUMBER)
expect(transactionRowMixin.vm.fedMembers).toStrictEqual([1])
expect(transactionRowMixin.vm.token.symbol).toBe(TUSD_TOKEN_SYMBOL)
expect(transactionRowMixin.vm.txExplorerLink).toBe(
`${TEST_NET_RSK_CROSS_KOVAN_CONFIG.explorer}/tx/${TRANSACTION_HASH}`,
)
Expand Down
39 changes: 33 additions & 6 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2614,21 +2614,30 @@
resolved "https://registry.yarnpkg.com/@rsksmart/ipfs-cpinner-client-types/-/ipfs-cpinner-client-types-0.1.3.tgz#a662ff57dbf6ae2da438d8c4f48bda30eac1c28e"
integrity sha512-SKHgsjVysiIVv6xyDOVuubVPVT7qMQ0y7IWOj2j73Hmgq/dSgyouXc2kl6THh0Vqh9ri5J3R+rKuXRzXmv/HvA==

"@rsksmart/mock-web3-provider@^1.0.0":
version "1.0.1"
resolved "https://registry.yarnpkg.com/@rsksmart/mock-web3-provider/-/mock-web3-provider-1.0.1.tgz#0f46fdea74018369631a4180814b3e0fe16a8d80"
integrity sha512-29syghh9X2ju80HXtH2O/tXEkUloCORo1lssLx70Trr1fiaxvpH5sxcFBDzjF0XPwwlrj3pqoQc34sL8EiUNYg==
dependencies:
eth-sig-util "^3.0.1"

"@rsksmart/rlogin-dpath@^1.0.1":
version "1.0.1"
resolved "https://registry.yarnpkg.com/@rsksmart/rlogin-dpath/-/rlogin-dpath-1.0.1.tgz#5ecb1d094d248231cbeda267c1fc5a779c8e46e3"
integrity sha512-97aalCxqCy6/JyE5eefka2isC9rU2hfvspQRfkvEVKB3zGJsC/xK0onDwCFH0kBCdkUn2K3lLO0GRnOStdbpIQ==

"@rsksmart/rlogin@^1.3.1-beta.2":
version "1.3.1-beta.3"
resolved "https://registry.yarnpkg.com/@rsksmart/rlogin/-/rlogin-1.3.1-beta.3.tgz#e4898b8363ca1bcb0ab3b6642e71b7a55496e3d3"
integrity sha512-uwLbssi0pBkN+5DSM+vmYjkfBgw+6QkB2s54GLk+wcsAhAIzFHDE/PzxZ50ttNDsLI6BvQ9qVAWOlZmjhiG6Wg==
"@rsksmart/rlogin@^1.3.3":
version "1.3.3"
resolved "https://registry.yarnpkg.com/@rsksmart/rlogin/-/rlogin-1.3.3.tgz#8db71b51513c84e65024e9ada986d0e507711672"
integrity sha512-VXFYBjO4qlcR+s/HtwmOYeQ8Lcae6lZgto9d5fsbliypxpF+CrUsfq8n6lLdGJSeeazWPTF7a2GnzLw9tqPSSA==
dependencies:
"@rsksmart/ipfs-cpinner-client-types" "^0.1.3"
"@rsksmart/mock-web3-provider" "^1.0.0"
"@rsksmart/rlogin-dpath" "^1.0.1"
"@rsksmart/vc-json-schemas-parser" "^1.0.0"
"@types/styled-components" "^5.1.3"
axios "^0.21.1"
buffer "^6.0.3"
ethr-did-resolver "^3.0.2"
i18next "^20.3.5"
i18next-browser-languagedetector "^6.1.2"
Expand Down Expand Up @@ -6401,7 +6410,7 @@ buffer-xor@^1.0.3:
resolved "https://registry.yarnpkg.com/buffer-xor/-/buffer-xor-1.0.3.tgz#26e61ed1422fb70dd42e6e36729ed51d855fe8d9"
integrity sha1-JuYe0UIvtw3ULm42cp7VHYVf6Nk=

buffer@6.0.3:
buffer@6.0.3, buffer@^6.0.3:
version "6.0.3"
resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.3.tgz#2ace578459cc8fbe2a70aaa8f52ee63b6a74c6c6"
integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==
Expand Down Expand Up @@ -9504,6 +9513,16 @@ eth-sig-util@^1.4.2:
ethereumjs-abi "git+https://github.com/ethereumjs/ethereumjs-abi.git"
ethereumjs-util "^5.1.1"

eth-sig-util@^3.0.1:
version "3.0.1"
resolved "https://registry.yarnpkg.com/eth-sig-util/-/eth-sig-util-3.0.1.tgz#8753297c83a3f58346bd13547b59c4b2cd110c96"
integrity sha512-0Us50HiGGvZgjtWTyAI/+qTzYPMLy5Q451D0Xy68bxq1QMWdoOddDwGvsqcFT27uohKgalM9z/yxplyt+mY2iQ==
dependencies:
ethereumjs-abi "^0.6.8"
ethereumjs-util "^5.1.1"
tweetnacl "^1.0.3"
tweetnacl-util "^0.15.0"

eth-tx-summary@^3.1.2:
version "3.2.4"
resolved "https://registry.yarnpkg.com/eth-tx-summary/-/eth-tx-summary-3.2.4.tgz#e10eb95eb57cdfe549bf29f97f1e4f1db679035c"
Expand Down Expand Up @@ -9566,6 +9585,14 @@ ethereumjs-abi@0.6.5:
bn.js "^4.10.0"
ethereumjs-util "^4.3.0"

ethereumjs-abi@^0.6.8:
version "0.6.8"
resolved "https://registry.yarnpkg.com/ethereumjs-abi/-/ethereumjs-abi-0.6.8.tgz#71bc152db099f70e62f108b7cdfca1b362c6fcae"
integrity sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==
dependencies:
bn.js "^4.11.8"
ethereumjs-util "^6.0.0"

"ethereumjs-abi@git+https://github.com/ethereumjs/ethereumjs-abi.git":
version "0.6.8"
resolved "git+https://github.com/ethereumjs/ethereumjs-abi.git#ee3994657fa7a427238e6ba92a84d0b529bbcde0"
Expand Down Expand Up @@ -19644,7 +19671,7 @@ tweetnacl@^0.14.3, tweetnacl@~0.14.0:
resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64"
integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=

tweetnacl@^1.0.0, tweetnacl@^1.0.1:
tweetnacl@^1.0.0, tweetnacl@^1.0.1, tweetnacl@^1.0.3:
version "1.0.3"
resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.3.tgz#ac0af71680458d8a6378d0d0d050ab1407d35596"
integrity sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==
Expand Down