question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Only loads spec files with .js extension

See original GitHub issue

I’m using jasmine-rails 0.12.2v with Sprockets and local Phantomjs. This is my jasmine.yml (I’m relying on assets pipeline):

# minimalist jasmine.yml configuration when leveraging asset pipeline
spec_files:
  - "**/*[Ss]pec.{js.jsx, js, jsx}"

use_phantom_gem: false

I’ve create a sample file (sample_spec.js.jsx) and when I try to run rake spec:javascripts it always throws:

ActionView::Template::Error: couldn't find file 'sample_spec.js.jsx' with type 'application/javascript'

On my environment, test will only run when using a .js extension for spec files.

Issue Analytics

  • State:open
  • Created 8 years ago
  • Comments:37 (10 by maintainers)

github_iconTop GitHub Comments

5reactions
mikemerrittcommented, Feb 19, 2016

Any updates on this?

0reactions
calebwoodscommented, Oct 7, 2016

I ended up tracking a similar issue to be caused by a Sprockets issuing react-rails https://github.com/reactjs/react-rails/issues/587

Read more comments on GitHub >

github_iconTop Results From Across the Web

Provide a way to add the '.js' file extension to the end ... - GitHub
I'm writing in typescript; importing something from a local path in the same project that only contains typescript files. How does appending a...
Read more >
How do I get a list of files with specific file extension using ...
Returns an array of filenames excluding '.' and '.. But how do I get a list of files matching a file specification, for...
Read more >
JavaScript modules - MDN Web Docs
This guide gives you all you need to get started with JavaScript module syntax.
Read more >
ts-node - npm
TypeScript execution environment and REPL for node.js, with source map support. Latest version: 10.9.1, last published: 6 months ago.
Read more >
Content Types - ESBuild
This loader is enabled by default for .js , .cjs , and .mjs files. The .cjs extension is used by node for CommonJS...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found