Skip to content

Lots of handlebars warnings with text+coverage reporter #9396

@sobolevn

Description

@sobolevn

🐛 Bug Report

I get this when I am running jest:

> cross-env NODE_ENV=test jest


[vue-jest]: no .babelrc found, skipping babel compilation


[vue-jest]: no .babelrc found, skipping babel compilation

 PASS  tests/pages/index.spec.ts (5.069s)
  unit tests for Index view
    ✓ should have three comments (36ms)
    ✓ should load new comments on actions (41ms)
  snapshot test for Index view
    ✓ should match the snapshot (72ms)

 PASS  tests/components/action-bar.spec.ts (5.061s)
  unit tests for ActionBar component
    ✓ should have one button (42ms)
    ✓ should call fetchComments action (7ms)
    ✓ should match the snapshot (33ms)

 PASS  tests/components/comment.spec.ts
  unit tests for Comment component
    ✓ should have valid props (28ms)
    ✓ should have two buttons (13ms)
    ✓ should have correct values (12ms)
    ✓ should change rating: {"delta": 1, "styleName": "comment-positive"} (10ms)
    ✓ should change rating: {"delta": -1, "styleName": "comment-negative"} (4ms)
  snapshot tests for Comment component
    ✓ should match the snapshot (17ms)

-------------------------|----------|----------|----------|----------|----------------
---|
File                     |  % Stmts | % Branch |  % Funcs |  % Lines | Uncovered Line 
#s |
-------------------------|----------|----------|----------|----------|----------------
---|
All files                |    95.97 |    82.35 |       90 |    96.94 |                   |
 components              |    95.45 |      100 |       80 |       95 |                   |
  ActionBar.vue          |      100 |      100 |      100 |      100 |                   |
  AppLogo.vue            |      100 |      100 |      100 |      100 |                   |
  Comment.vue            |    91.67 |      100 |       50 |    90.91 |                60 |
 logic                   |      100 |      100 |      100 |      100 |                   |
  store.ts               |      100 |      100 |      100 |      100 |                   |
  tokens.ts              |      100 |      100 |      100 |      100 |                   |
 logic/comments          |    95.12 |    77.78 |      100 |      100 |                   |
  models.ts              |      100 |      100 |      100 |      100 |                   |
  module.ts              |    94.87 |    77.78 |      100 |      100 |             50,56 |
 logic/comments/services |      100 |      100 |      100 |      100 |                   |
  api.ts                 |      100 |      100 |      100 |      100 |                   |
 mixins                  |      100 |      100 |      100 |      100 |                   |
  typed-store.ts         |      100 |      100 |      100 |      100 |                   |
 pages                   |    83.33 |      100 |       50 |    81.82 |                   |
  index.vue              |    83.33 |      100 |       50 |    81.82 |             56,57 |
 plugins                 |      100 |      100 |      100 |      100 |                   |
  type-di.ts             |      100 |      100 |      100 |      100 |                   |
 store                   |      100 |       50 |      100 |      100 |                   |
  index.ts               |      100 |       50 |      100 |      100 |                30 |
-------------------------|----------|----------|----------|----------|-------------------|
Handlebars: Access has been denied to resolve the property "statements" because it is not an "own property" of its parent.
You can add a runtime option to disable the check or this warning:
See http://localhost:8080/api-reference/runtime-options.html#options-to-control-prototype-access for details
...

Problem part:

Handlebars: Access has been denied to resolve the property "statements" because it is not an "own property" of its parent.
You can add a runtime option to disable the check or this warning:
See http://localhost:8080/api-reference/runtime-options.html#options-to-control-prototype-access for details

It is actually VERY long. It has like hundreds of lines.
Full log is here: https://travis-ci.com/wemake-services/wemake-vue-template/builds/143977902#L759

To Reproduce

Steps to reproduce the behavior:

  1. Create new app: https://github.com/wemake-services/wemake-vue-template
  2. Install deps with npm i
  3. Run npm test

Expected behavior

I expect the tests to pass without any warnings.

envinfo

» npx envinfo --preset jest
npx: installed 1 in 1.988s

  System:
    OS: macOS Mojave 10.14.5
    CPU: (4) x64 Intel(R) Core(TM) i5-5257U CPU @ 2.70GHz
  Binaries:
    Node: 12.14.0 - ~/.nvm/versions/node/v12.14.0/bin/node
    Yarn: 1.9.4 - /usr/local/bin/yarn
    npm: 6.13.4 - ~/.nvm/versions/node/v12.14.0/bin/npm
  npmPackages:
    jest: ^24.9.0 => 24.9.0 

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions