git.delta.rocks / unique-network / refs/commits / 31fca6536571

difftreelog

Add no-floating-promises rule to eslint

Max Andreev2022-12-22parent: #72b9c7c.patch.diff
in: master

6 files changed

modifiedtests/.eslintrc.jsondiffbeforeafterboth
18 "mocha"18 "mocha"
19 ],19 ],
20 "rules": {20 "rules": {
21 "@typescript-eslint/no-floating-promises": [
22 "error"
23 ],
21 "indent": [24 "indent": [
22 "error",25 "error",
23 2,26 2,
modifiedtests/package.jsondiffbeforeafterboth
11 "@types/chai-subset": "^1.3.3",11 "@types/chai-subset": "^1.3.3",
12 "@types/mocha": "^10.0.0",12 "@types/mocha": "^10.0.0",
13 "@types/node": "^18.11.2",13 "@types/node": "^18.11.2",
14 "@typescript-eslint/eslint-plugin": "^5.40.1",14 "@typescript-eslint/eslint-plugin": "^5.47.0",
15 "@typescript-eslint/parser": "^5.40.1",15 "@typescript-eslint/parser": "^5.47.0",
16 "chai": "^4.3.6",16 "chai": "^4.3.6",
17 "chai-subset": "^1.6.0",17 "chai-subset": "^1.6.0",
18 "eslint": "^8.25.0",18 "eslint": "^8.25.0",
modifiedtests/src/calibrate.tsdiffbeforeafterboth
295 }295 }
296}296}
297297
298// eslint-disable-next-line @typescript-eslint/no-floating-promises
298(async () => {299(async () => {
299 await usingEthPlaygrounds(async (helper: EthUniqueHelper, privateKey) => {300 await usingEthPlaygrounds(async (helper: EthUniqueHelper, privateKey) => {
300 // Subsequent runs reduce error, as price line is not actually straight, this is a curve301 // Subsequent runs reduce error, as price line is not actually straight, this is a curve
modifiedtests/src/transfer.nload.tsdiffbeforeafterboth
14// You should have received a copy of the GNU General Public License14// You should have received a copy of the GNU General Public License
15// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.15// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
1616
17/* eslint-disable @typescript-eslint/no-floating-promises */
17import os from 'os';18import os from 'os';
18import {IKeyringPair} from '@polkadot/types/types';19import {IKeyringPair} from '@polkadot/types/types';
19import {usingPlaygrounds} from './util';20import {usingPlaygrounds} from './util';
modifiedtests/src/util/globalSetup.tsdiffbeforeafterboth
17 // 2. Create donors for test files17 // 2. Create donors for test files
18 await fundFilenamesWithRetries(3)18 await fundFilenamesWithRetries(3)
19 .then((result) => {19 .then((result) => {
20 if (!result) Promise.reject();20 if (!result) throw Error('Some problems with fundFilenamesWithRetries');
21 });21 });
2222
23 // 3. Configure App Promotion23 // 3. Configure App Promotion
38 }38 }
39 } catch (error) {39 } catch (error) {
40 console.error(error);40 console.error(error);
41 Promise.reject();41 throw Error('Error during globalSetup');
42 }42 }
43 });43 });
44};44};
modifiedtests/yarn.lockdiffbeforeafterboth
1064 dependencies:1064 dependencies:
1065 "@types/node" "*"1065 "@types/node" "*"
10661066
1067"@typescript-eslint/eslint-plugin@^5.40.1":1067"@typescript-eslint/eslint-plugin@^5.47.0":
1068 version "5.46.1"1068 version "5.47.0"
1069 resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.46.1.tgz#098abb4c9354e19f460d57ab18bff1f676a6cff0"1069 resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.47.0.tgz#dadb79df3b0499699b155839fd6792f16897d910"
1070 integrity sha512-YpzNv3aayRBwjs4J3oz65eVLXc9xx0PDbIRisHj+dYhvBn02MjYOD96P8YGiWEIFBrojaUjxvkaUpakD82phsA==1070 integrity sha512-AHZtlXAMGkDmyLuLZsRpH3p4G/1iARIwc/T0vIem2YB+xW6pZaXYXzCBnZSF/5fdM97R9QqZWZ+h3iW10XgevQ==
1071 dependencies:1071 dependencies:
1072 "@typescript-eslint/scope-manager" "5.46.1"1072 "@typescript-eslint/scope-manager" "5.47.0"
1073 "@typescript-eslint/type-utils" "5.46.1"1073 "@typescript-eslint/type-utils" "5.47.0"
1074 "@typescript-eslint/utils" "5.46.1"1074 "@typescript-eslint/utils" "5.47.0"
1075 debug "^4.3.4"1075 debug "^4.3.4"
1076 ignore "^5.2.0"1076 ignore "^5.2.0"
1077 natural-compare-lite "^1.4.0"1077 natural-compare-lite "^1.4.0"
1078 regexpp "^3.2.0"1078 regexpp "^3.2.0"
1079 semver "^7.3.7"1079 semver "^7.3.7"
1080 tsutils "^3.21.0"1080 tsutils "^3.21.0"
10811081
1082"@typescript-eslint/parser@^5.40.1":1082"@typescript-eslint/parser@^5.47.0":
1083 version "5.46.1"1083 version "5.47.0"
1084 resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.46.1.tgz#1fc8e7102c1141eb64276c3b89d70da8c0ba5699"1084 resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.47.0.tgz#62e83de93499bf4b500528f74bf2e0554e3a6c8d"
1085 integrity sha512-RelQ5cGypPh4ySAtfIMBzBGyrNerQcmfA1oJvPj5f+H4jI59rl9xxpn4bonC0tQvUKOEN7eGBFWxFLK3Xepneg==1085 integrity sha512-udPU4ckK+R1JWCGdQC4Qa27NtBg7w020ffHqGyAK8pAgOVuNw7YaKXGChk+udh+iiGIJf6/E/0xhVXyPAbsczw==
1086 dependencies:1086 dependencies:
1087 "@typescript-eslint/scope-manager" "5.46.1"1087 "@typescript-eslint/scope-manager" "5.47.0"
1088 "@typescript-eslint/types" "5.46.1"1088 "@typescript-eslint/types" "5.47.0"
1089 "@typescript-eslint/typescript-estree" "5.46.1"1089 "@typescript-eslint/typescript-estree" "5.47.0"
1090 debug "^4.3.4"1090 debug "^4.3.4"
10911091
1092"@typescript-eslint/scope-manager@5.46.1":1092"@typescript-eslint/scope-manager@5.47.0":
1093 version "5.46.1"1093 version "5.47.0"
1094 resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.46.1.tgz#70af8425c79bbc1178b5a63fb51102ddf48e104a"1094 resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.47.0.tgz#f58144a6b0ff58b996f92172c488813aee9b09df"
1095 integrity sha512-iOChVivo4jpwUdrJZyXSMrEIM/PvsbbDOX1y3UCKjSgWn+W89skxWaYXACQfxmIGhPVpRWK/VWPYc+bad6smIA==1095 integrity sha512-dvJab4bFf7JVvjPuh3sfBUWsiD73aiftKBpWSfi3sUkysDQ4W8x+ZcFpNp7Kgv0weldhpmMOZBjx1wKN8uWvAw==
1096 dependencies:1096 dependencies:
1097 "@typescript-eslint/types" "5.46.1"1097 "@typescript-eslint/types" "5.47.0"
1098 "@typescript-eslint/visitor-keys" "5.46.1"1098 "@typescript-eslint/visitor-keys" "5.47.0"
10991099
1100"@typescript-eslint/type-utils@5.46.1":1100"@typescript-eslint/type-utils@5.47.0":
1101 version "5.46.1"1101 version "5.47.0"
1102 resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.46.1.tgz#195033e4b30b51b870dfcf2828e88d57b04a11cc"1102 resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.47.0.tgz#2b440979c574e317d3473225ae781f292c99e55d"
1103 integrity sha512-V/zMyfI+jDmL1ADxfDxjZ0EMbtiVqj8LUGPAGyBkXXStWmCUErMpW873zEHsyguWCuq2iN4BrlWUkmuVj84yng==1103 integrity sha512-1J+DFFrYoDUXQE1b7QjrNGARZE6uVhBqIvdaXTe5IN+NmEyD68qXR1qX1g2u4voA+nCaelQyG8w30SAOihhEYg==
1104 dependencies:1104 dependencies:
1105 "@typescript-eslint/typescript-estree" "5.46.1"1105 "@typescript-eslint/typescript-estree" "5.47.0"
1106 "@typescript-eslint/utils" "5.46.1"1106 "@typescript-eslint/utils" "5.47.0"
1107 debug "^4.3.4"1107 debug "^4.3.4"
1108 tsutils "^3.21.0"1108 tsutils "^3.21.0"
11091109
1110"@typescript-eslint/types@5.46.1":1110"@typescript-eslint/types@5.47.0":
1111 version "5.46.1"1111 version "5.47.0"
1112 resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.46.1.tgz#4e9db2107b9a88441c4d5ecacde3bb7a5ebbd47e"1112 resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.47.0.tgz#67490def406eaa023dbbd8da42ee0d0c9b5229d3"
1113 integrity sha512-Z5pvlCaZgU+93ryiYUwGwLl9AQVB/PQ1TsJ9NZ/gHzZjN7g9IAn6RSDkpCV8hqTwAiaj6fmCcKSQeBPlIpW28w==1113 integrity sha512-eslFG0Qy8wpGzDdYKu58CEr3WLkjwC5Usa6XbuV89ce/yN5RITLe1O8e+WFEuxnfftHiJImkkOBADj58ahRxSg==
11141114
1115"@typescript-eslint/typescript-estree@5.46.1":1115"@typescript-eslint/typescript-estree@5.47.0":
1116 version "5.46.1"1116 version "5.47.0"
1117 resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.46.1.tgz#5358088f98a8f9939355e0996f9c8f41c25eced2"1117 resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.47.0.tgz#ed971a11c5c928646d6ba7fc9dfdd6e997649aca"
1118 integrity sha512-j9W4t67QiNp90kh5Nbr1w92wzt+toiIsaVPnEblB2Ih2U9fqBTyqV9T3pYWZBRt6QoMh/zVWP59EpuCjc4VRBg==1118 integrity sha512-LxfKCG4bsRGq60Sqqu+34QT5qT2TEAHvSCCJ321uBWywgE2dS0LKcu5u+3sMGo+Vy9UmLOhdTw5JHzePV/1y4Q==
1119 dependencies:1119 dependencies:
1120 "@typescript-eslint/types" "5.46.1"1120 "@typescript-eslint/types" "5.47.0"
1121 "@typescript-eslint/visitor-keys" "5.46.1"1121 "@typescript-eslint/visitor-keys" "5.47.0"
1122 debug "^4.3.4"1122 debug "^4.3.4"
1123 globby "^11.1.0"1123 globby "^11.1.0"
1124 is-glob "^4.0.3"1124 is-glob "^4.0.3"
1125 semver "^7.3.7"1125 semver "^7.3.7"
1126 tsutils "^3.21.0"1126 tsutils "^3.21.0"
11271127
1128"@typescript-eslint/utils@5.46.1":1128"@typescript-eslint/utils@5.47.0":
1129 version "5.46.1"1129 version "5.47.0"
1130 resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.46.1.tgz#7da3c934d9fd0eb4002a6bb3429f33298b469b4a"1130 resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.47.0.tgz#b5005f7d2696769a1fdc1e00897005a25b3a0ec7"
1131 integrity sha512-RBdBAGv3oEpFojaCYT4Ghn4775pdjvwfDOfQ2P6qzNVgQOVrnSPe5/Pb88kv7xzYQjoio0eKHKB9GJ16ieSxvA==1131 integrity sha512-U9xcc0N7xINrCdGVPwABjbAKqx4GK67xuMV87toI+HUqgXj26m6RBp9UshEXcTrgCkdGYFzgKLt8kxu49RilDw==
1132 dependencies:1132 dependencies:
1133 "@types/json-schema" "^7.0.9"1133 "@types/json-schema" "^7.0.9"
1134 "@types/semver" "^7.3.12"1134 "@types/semver" "^7.3.12"
1135 "@typescript-eslint/scope-manager" "5.46.1"1135 "@typescript-eslint/scope-manager" "5.47.0"
1136 "@typescript-eslint/types" "5.46.1"1136 "@typescript-eslint/types" "5.47.0"
1137 "@typescript-eslint/typescript-estree" "5.46.1"1137 "@typescript-eslint/typescript-estree" "5.47.0"
1138 eslint-scope "^5.1.1"1138 eslint-scope "^5.1.1"
1139 eslint-utils "^3.0.0"1139 eslint-utils "^3.0.0"
1140 semver "^7.3.7"1140 semver "^7.3.7"
11411141
1142"@typescript-eslint/visitor-keys@5.46.1":1142"@typescript-eslint/visitor-keys@5.47.0":
1143 version "5.46.1"1143 version "5.47.0"
1144 resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.46.1.tgz#126cc6fe3c0f83608b2b125c5d9daced61394242"1144 resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.47.0.tgz#4aca4efbdf6209c154df1f7599852d571b80bb45"
1145 integrity sha512-jczZ9noovXwy59KjRTk1OftT78pwygdcmCuBf8yMoWt/8O8l+6x2LSEze0E4TeepXK4MezW3zGSyoDRZK7Y9cg==1145 integrity sha512-ByPi5iMa6QqDXe/GmT/hR6MZtVPi0SqMQPDx15FczCBXJo/7M8T88xReOALAfpBLm+zxpPfmhuEvPb577JRAEg==
1146 dependencies:1146 dependencies:
1147 "@typescript-eslint/types" "5.46.1"1147 "@typescript-eslint/types" "5.47.0"
1148 eslint-visitor-keys "^3.3.0"1148 eslint-visitor-keys "^3.3.0"
11491149
1150abortcontroller-polyfill@^1.7.3:1150abortcontroller-polyfill@^1.7.3: