1859

Testcafe live not running

<h3>Question</h3>

I am on OsX, using nvm, node 10.15.3. Testscafe (not live) works fine, but I was trying to follow the instructions at Testcafe-live

At the step where it explains how to install it locally

<blockquote>

If you have installed testcafe-live locally to your project, add an npm script to package.json to run tests:

</blockquote>

it refers to a package.json file, I added the entry under the scripts section

"scripts": { "test": "eslint ./**/*.js", "testcafe-live": "testcafe-live chrome tests/" },

but when I run

<blockquote>

npm run testcafe-live

</blockquote>

I get these errors:

npm ERR! path /Users/Thomas.Pavan/testcafe/package.json npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall open npm ERR! enoent ENOENT: no such file or directory, open '/Users/Thomas.Pavan/testcafe/package.json' npm ERR! enoent This is related to npm not being able to find a file. npm ERR! enoent npm ERR! A complete log of this run can be found in: npm ERR! /Users/Thomas.Pavan/.npm/_logs/2019-03-11T14_58_28_946Z-debug.log

I see that the package.json path is the problem, my package.json file is in ~/testcafe/node_modules/testcafe-live but npm is looking at /Users/Thomas.Pavan/testcafe/. I'm confused if I installed testcafe-live in the wrong location (currently at ~/testcafe) my project root folder, and I also don't understand where I can change the path shown in the error. Long story short, the package.json file should be in the root of my folder but installing testcafe-live as instructed, creates a node_modules folder and the package.json file is nested there.


<h3>Answer1:</h3>

Thank you for your interest in TestCafe. Starting from version 1.0.0 TestCafe has a built-in Live mode feature and it does not require any external module. The repository you mentioned is obsolete now. Please refer to the following article to get more details https://devexpress.github.io/testcafe/documentation/using-testcafe/common-concepts/live-mode.html  

来源:https://stackoverflow.com/questions/55105328/testcafe-live-not-running

Recommend

  • Cannot get file data from the clipboard using Flex
  • Running Rails code/initializers but not via Rake
  • Default namespace & complex package/data structure
  • XCode 5 crash on loading the project
  • How to apply CSS to document.write()?
  • can I build CMakeLists.txt from a set of smaller files (to improve the readability and maintainabili
  • How to use CoreFoundation in QuickTime SDK for Windows?
  • OpenCV::solvePNP() - Assertion failed
  • Making query to find nearest multiple(Lat,Long) from the single(Lat,Long)
  • Ways of filling 10 places with number from [1..10] such that digit at ith place has value atmost 1 m
  • async GET request with body from browser
  • How can I run an Illustrator javascript on all files in a directory?
  • Align microsoft access queries
  • Scripting Support For Image Filtering in DigitalMicrograph
  • Authorize Attribute Authentication with Postman in Web Api
  • Symfony - Setting Cookie onKernelRequest
  • Javascript inside HTML import not affecting imported HTML
  • Swift manually rotate view controller
  • How to define a custom accuracy in Keras to ignore samples with a particular gold label?
  • C# code can't “see” the methods in my C++ dll
  • Splitting ReportLab table across PDF page (side by side)?
  • Does hibernate load two seprate copies of same instance if they are loaded twice from database?
  • Julia 1.0 UndefVarError - Scope of Variable
  • JavaMail connection problems [duplicate]
  • Copy and paste data from multiple workbooks to a worksheet in another Workbook
  • 'Edit' function for forum posts and such
  • Java .policy file - how to prevent java.util.Date() from being accessible
  • How to create subsets of a single set of elements with XSLT?
  • How to compile gSoap with ssl enabled on windows?
  • How to use Kaminari pagination gem with Sinatra and Mongoid?
  • How to write seo friendly url's using htaccess?
  • Create an average of multiple excel chart without the data source
  • how to run ejabberd with Erlang on Heroku?
  • How to use Streams api peek() function and make it work?
  • `$http:badreq Bad Request Configuration` - from angular post method, what is wrong here?
  • read part of h5 dataset python
  • Background transfer download task failed when app was closed
  • convert json to excel in java