Skip to content

GraphQL error preventing tests being shown #222

Open
@IPWright83

Description

@IPWright83

Is this a bug report or a feature request?

Bug

Version Info

  • Version of Majestic: 1.8.1
  • Version of Jest: 6.14.12
  • Version of Node: 12.22.1
  • Operating System: Ubuntu 20.04.3

Reproduction Repo

I can't really provide a quick reproduction, but I am happy to dig and find more information to diagnose. Essentially I get no tests shown in the file window for 1 particular file. I've not encountered this issue with any other files:

image

When selecting the file I encounter the following error in the console:

Uncaught (in promise) Error: GraphQL error: Unexpected token (7:12)
    at new t (ui.bundle.js:21)
    at e.<anonymous> (ui.bundle.js:21)
    at ui.bundle.js:16
    at Object.next (ui.bundle.js:16)
    at ui.bundle.js:16
    at new Promise (<anonymous>)
    at l (ui.bundle.js:16)
    at ui.bundle.js:21
    at ui.bundle.js:21
    at Array.forEach (<anonymous>)
t @ ui.bundle.js:21
(anonymous) @ ui.bundle.js:21
(anonymous) @ ui.bundle.js:16
(anonymous) @ ui.bundle.js:16
(anonymous) @ ui.bundle.js:16
l @ ui.bundle.js:16
(anonymous) @ ui.bundle.js:21
(anonymous) @ ui.bundle.js:21
(anonymous) @ ui.bundle.js:21
e.broadcastQueries @ ui.bundle.js:21
(anonymous) @ ui.bundle.js:21
(anonymous) @ ui.bundle.js:16
(anonymous) @ ui.bundle.js:16
(anonymous) @ ui.bundle.js:16
l @ ui.bundle.js:16
next @ ui.bundle.js:21
g @ ui.bundle.js:51
b @ ui.bundle.js:51
value @ ui.bundle.js:51
(anonymous) @ ui.bundle.js:21
next @ ui.bundle.js:21
g @ ui.bundle.js:51
b @ ui.bundle.js:51
value @ ui.bundle.js:51
(anonymous) @ ui.bundle.js:92
Promise.then (async)
(anonymous) @ ui.bundle.js:21
ha @ ui.bundle.js:42
(anonymous) @ ui.bundle.js:42
c @ ui.bundle.js:51
d @ ui.bundle.js:51
B.port1.onmessage @ ui.bundle.js:51

The pre-ceding request if it's helpful is this. I've looked for odd characters in the describe/it names but can't see anything out of sorts.

{result: {…}}
  result:
    consoleLogs: null
    failureMessage: null
    numFailingTests: 0
    numPassingTests: 5
    path: "/home/ian/src/webclient/app/src/views/solutions/components/PaginatedTable/PaginatedTable.test.tsx"
    testResults: Array(5)
      0: {title: 'with no data', numPassingAsserts: 0, status: 'passed', failureMessages: Array(0), ancestorTitles: Array(2), …}
      1: {title: 'with data', numPassingAsserts: 0, status: 'passed', failureMessages: Array(0), ancestorTitles: Array(2), …}
      2: {title: 'with a custom header cell', numPassingAsserts: 0, status: 'passed', failureMessages: Array(0), ancestorTitles: Array(2), …}
      3: {title: 'with a custom data cell', numPassingAsserts: 0, status: 'passed', failureMessages: Array(0), ancestorTitles: Array(2), …}
      4: {title: 'with more than 8 rows', numPassingAsserts: 0, status: 'passed', failureMessages: Array(0), ancestorTitles: Array(2), …}
      length: 5
      [[Prototype]]: Array(0)
      __typename: "TestFileResult"
    [[Prototype]]: Object
  [[Prototype]]: Object

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions