mirror of
https://github.com/r0adkll/sign-android-release
synced 2026-09-30 08:38:39 +00:00
bump jest and make tests pass
This commit is contained in:
+3
-1
@@ -11,6 +11,8 @@ exports.default = convertDescriptorToString;
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
|
||||
/* eslint-disable local/ban-types-eventually */
|
||||
// See: https://github.com/facebook/jest/pull/5154
|
||||
function convertDescriptorToString(descriptor) {
|
||||
if (
|
||||
@@ -31,7 +33,7 @@ function convertDescriptorToString(descriptor) {
|
||||
|
||||
const stringified = descriptor.toString();
|
||||
const typeDescriptorMatch = stringified.match(/class|function/);
|
||||
const indexOfNameSpace = // @ts-ignore: typeDescriptorMatch exists
|
||||
const indexOfNameSpace = // @ts-expect-error: typeDescriptorMatch exists
|
||||
typeDescriptorMatch.index + typeDescriptorMatch[0].length;
|
||||
const indexOfNameAfterSpace = stringified.search(/\(|\{/);
|
||||
const name = stringified.substring(indexOfNameSpace, indexOfNameAfterSpace);
|
||||
|
||||
Reference in New Issue
Block a user