Skip to main content

All Questions

Tagged with
-1 votes
1 answer
485 views

AVA Unit Test: Use gulp-ava to test global functions

I'm new on using AVA for JS unit tests and I immediately hit a rock: My situation is that I want to run a gulp task to run the AVA tests and watch the test files, and in the test file I wrote I need ...
J. Doe's user avatar
  • 1
0 votes
1 answer
338 views

Decouple Knockout dependencies in Jasmine unit tests

I am introducing javascript unit tests to my company's application. I've worked predominantly with AngularJS, but their framework of choice is Knockout. The code is relatively modular in design (...
cidthecoatrack's user avatar
0 votes
1 answer
658 views

how to add navigator.geolocation.getCurrentPosition in phantomjs+jasmine+requirejs env

I just phantomjs + jasmine + requirejs + saga to test JavaScript codes. I used the way to mock navigator.geolocation.getcurrentposition following 0 in Does phantomJS support geolocations? My ...
Sunny's user avatar
  • 1
1 vote
2 answers
2k views

Karma test run with Jasmine cannot find TypeScript module

I want to test my TypeScript code with Jasmine executed by Karma. Unfortunately the Karma is unable to find my module and exists with "Module name has not been loaded yet for context". My ...
Benny Code's user avatar
  • 53.8k
0 votes
1 answer
65 views

Jasmine & requirejs support for multi modules?

I am currently using Jasmine ("jasmine": "^2.4.1") with Node v6.1.0 I am both trying to provide and consume multiple modules in one file - however keep getting errors like object undefined or null ...
shenku's user avatar
  • 12.3k
3 votes
1 answer
318 views

Coverage.json not generated with Jasmine RequireJS and Istanbul in grunt

I have trying to generate coverage report based from grunt using grunt-template-jasmine-istanbul. The Specs are executed correctly but no coverage report is generated. Below is my code in the config ...
Arun Kumar's user avatar
0 votes
1 answer
79 views

Karma test run throwing error on requirejs

I have the below configuration in the karma config file. frameworks: [ 'jasmine', 'requirejs' ], files: [ //App Bower components {pattern: 'public/...
Priyabrat Nanda's user avatar
0 votes
0 answers
81 views

Running Jasmine tests from Node against code that uses RequireJS

Is it possible to run Jasmine from Node to test code that uses RequireJS? I am using the Jasmine NPM. I can run some tests from Node but can't work out how to test my code that uses RequireJS. V2 of ...
James's user avatar
  • 71
3 votes
2 answers
643 views

PhantomJS not playing nice with RequireJS+Jasmine

I have some tests running with RequireJS and Jasmine. I have a Jasmine test harness file that looks like this: <html> <head> <meta charset="utf-8" /> <link rel="...
user3715648's user avatar
  • 1,568
5 votes
1 answer
705 views

State of Jasmine Unit Test support of Resharper 2017: Debug mode and AMD modules supported?

I currently use Chutzpah to run and debug Jasmine Unit tests that include AMD/require.js modules. I would like switch to the test runner of Resharper 2017. However, Resharper does not seem to fully ...
Stefan's user avatar
  • 11.6k
0 votes
1 answer
101 views

Angular-Jasmine, loading json

I am trying to load json from local folder and then feed it into function to test it. Here is what I am trying to do: it('should be able to use treatExpResultJSON() function to treat incoming JSON', ...
Nikita Vlasenko's user avatar
0 votes
1 answer
64 views

How to make requirejs to work with jasmine and blanketjs for code coverage?

I was working on generating code coverage report using blanketjs. Click here . But I am finding difficulty in achieving the same. Here's my code : require(['jquery', 'boot', 'JasmineBlanket'], ...
graphics123's user avatar
  • 1,261
0 votes
1 answer
288 views

Knockout, requirejs and Jasmine test fails

I've got a knockout component with the following view model: define(["jquery", "knockout"], function ($, ko) { return function () { function companySet(value) { var self =...
cloggins's user avatar
  • 669
1 vote
0 answers
138 views

Istanbul coverage with built React JavaScript and Jasmine

I have a built version of a React module that I'm testing successfully with Jasmine but when I try to use Istanbul to determine my tests coverage it shows that I'm only testing the Require.js Define ...
sbason's user avatar
  • 11
0 votes
1 answer
826 views

Jasmine Testing knockout.js with requirejs

I am having trouble getting my Jasmine test file to get data from my knockoutjs files. I am able to create knockout observables and test those in the the spec file but not other files. For some reason ...
laskdjf's user avatar
  • 1,172

15 30 50 per page
1
2
3 4 5
10