Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SystemJS was not found #171

Open
ghost opened this issue Jul 19, 2016 · 3 comments
Open

SystemJS was not found #171

ghost opened this issue Jul 19, 2016 · 3 comments

Comments

@ghost
Copy link

ghost commented Jul 19, 2016

Hi. I having the following problem with karma-jspm. I setup the karma.conf.js file apparently properly and it's giving me the following error:

Uncaught Error: SystemJS was not found. Please make sure you have initialized jspm via installing a dependency with jspm, or by running 'jspm dl-loader'.

karma.conf.js:

module.exports = function(config) {
    config.set({
        basePath: "",
        frameworks: ["jasmine", "jspm"],
        jspm: {
            config: "extension/config.js",
            packages: "extension/jspm_packages/",
            serveFiles: ["extension/**/*.js"],
            loadFiles: ["extension/build/test/**/*.js"],
            paths: {
                "*": "base/extension/build/*",
                "github:*": "base/extension/jspm_packages/github/*",
                "npm:*": "base/extension/jspm_packages/npm/*",
                "vendor/*": "base/extension/vendor/*",
                "injected-css/*": "base/extension/inject/*"
            },
        },
        files: [],
        exclude: [],
        reporters: ["progress"],
        port: 9876,
        colors: true,
        logLevel: config.LOG_INFO,
        autoWatch: true,
        browsers: ["Chrome"],
        singleRun: false
    });
};

SystemJs config file is: extension/config.js and it's working fine (outside the test environment).

So, how I tell karma-jspm the way to find SystemJs?

Thanks.

@Roshanjossey
Copy link

I came across the same problem. I fixed it by taking the following steps

  • Install jspm globally. npm install -g jspm
  • Now initialise jspm. jspm dl-loader You'll get some prompts like the following.

Would you like jspm to prefix the jspm package.json properties under jspm? [yes]:yes
Enter server baseURL (public folder path) [./]:
Enter jspm packages folder [./jspm_packages]:
Enter config file path [./config.js]:
Configuration file config.js doesn't exist, create it? [yes]:
Enter client baseURL (public folder URL) [/]:
Do you wish to use a transpiler? [yes]:yes
Which ES6 transpiler would you like to use, Babel, TypeScript or Traceur? [babel]:

@peteringram0
Copy link

What version of JSPM are you running? I am getting the same issue with the latest beta version

@dwilson6
Copy link
Contributor

Here's a PR to fix this issue with the jspm 0.17 beta 41 and karma-jspm: #187

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants