From 37914cb83b91ca6ee71eac47308203bdbc95161b Mon Sep 17 00:00:00 2001 From: Gareth Jones Date: Sun, 23 Aug 2020 11:02:38 +1200 Subject: [PATCH] chore: upgrade to `typescript@4` --- package.json | 2 +- src/rules/no-focused-tests.ts | 1 + yarn.lock | 8 ++++---- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 70b3bff99..a0cec8eb1 100644 --- a/package.json +++ b/package.json @@ -120,7 +120,7 @@ "rimraf": "^3.0.0", "semantic-release": "^17.0.7", "ts-node": "^9.0.0", - "typescript": "^3.5.3" + "typescript": "^4.0.0" }, "peerDependencies": { "eslint": ">=5" diff --git a/src/rules/no-focused-tests.ts b/src/rules/no-focused-tests.ts index eb7cd2610..d0af58d81 100644 --- a/src/rules/no-focused-tests.ts +++ b/src/rules/no-focused-tests.ts @@ -30,6 +30,7 @@ const isConcurrentExpression = ( const matchesTestFunction = (object: TSESTree.LeftHandSideExpression) => 'name' in object && + typeof object.name === 'string' && (object.name in TestCaseName || object.name in DescribeAlias); const isCallToFocusedTestFunction = (object: TSESTree.Identifier) => diff --git a/yarn.lock b/yarn.lock index e7bbb3ec2..b3791422a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8517,10 +8517,10 @@ typedarray@^0.0.6: resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= -typescript@^3.5.3: - version "3.9.7" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.9.7.tgz#98d600a5ebdc38f40cb277522f12dc800e9e25fa" - integrity sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw== +typescript@^4.0.0: + version "4.0.2" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.0.2.tgz#7ea7c88777c723c681e33bf7988be5d008d05ac2" + integrity sha512-e4ERvRV2wb+rRZ/IQeb3jm2VxBsirQLpQhdxplZ2MEzGvDkkMmPglecnNDfSUBivMjP93vRbngYYDQqQ/78bcQ== uglify-js@^3.1.4: version "3.10.1"