{"action":"closed","issue":{"url":"https://api.github.com/repos/angular/angular-cli/issues/2206","repository_url":"https://api.github.com/repos/angular/angular-cli","labels_url":"https://api.github.com/repos/angular/angular-cli/issues/2206/labels{/name}","comments_url":"https://api.github.com/repos/angular/angular-cli/issues/2206/comments","events_url":"https://api.github.com/repos/angular/angular-cli/issues/2206/events","html_url":"https://github.com/angular/angular-cli/issues/2206","id":177676288,"number":2206,"title":"Karma throws errors when using custom source directory","user":{"login":"kucharzyk","id":5682894,"avatar_url":"https://avatars.githubusercontent.com/u/5682894?v=3","gravatar_id":"","url":"https://api.github.com/users/kucharzyk","html_url":"https://github.com/kucharzyk","followers_url":"https://api.github.com/users/kucharzyk/followers","following_url":"https://api.github.com/users/kucharzyk/following{/other_user}","gists_url":"https://api.github.com/users/kucharzyk/gists{/gist_id}","starred_url":"https://api.github.com/users/kucharzyk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kucharzyk/subscriptions","organizations_url":"https://api.github.com/users/kucharzyk/orgs","repos_url":"https://api.github.com/users/kucharzyk/repos","events_url":"https://api.github.com/users/kucharzyk/events{/privacy}","received_events_url":"https://api.github.com/users/kucharzyk/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/angular/angular-cli/labels/command:%20new","name":"command: new","color":"c7def8"},{"url":"https://api.github.com/repos/angular/angular-cli/labels/priority:%202%20(required)","name":"priority: 2 (required)","color":"0052cc"},{"url":"https://api.github.com/repos/angular/angular-cli/labels/type:%20bug","name":"type: bug","color":"EEEEEE"}],"state":"closed","locked":false,"assignee":{"login":"filipesilva","id":4172079,"avatar_url":"https://avatars.githubusercontent.com/u/4172079?v=3","gravatar_id":"","url":"https://api.github.com/users/filipesilva","html_url":"https://github.com/filipesilva","followers_url":"https://api.github.com/users/filipesilva/followers","following_url":"https://api.github.com/users/filipesilva/following{/other_user}","gists_url":"https://api.github.com/users/filipesilva/gists{/gist_id}","starred_url":"https://api.github.com/users/filipesilva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/filipesilva/subscriptions","organizations_url":"https://api.github.com/users/filipesilva/orgs","repos_url":"https://api.github.com/users/filipesilva/repos","events_url":"https://api.github.com/users/filipesilva/events{/privacy}","received_events_url":"https://api.github.com/users/filipesilva/received_events","type":"User","site_admin":false},"assignees":[{"login":"filipesilva","id":4172079,"avatar_url":"https://avatars.githubusercontent.com/u/4172079?v=3","gravatar_id":"","url":"https://api.github.com/users/filipesilva","html_url":"https://github.com/filipesilva","followers_url":"https://api.github.com/users/filipesilva/followers","following_url":"https://api.github.com/users/filipesilva/following{/other_user}","gists_url":"https://api.github.com/users/filipesilva/gists{/gist_id}","starred_url":"https://api.github.com/users/filipesilva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/filipesilva/subscriptions","organizations_url":"https://api.github.com/users/filipesilva/orgs","repos_url":"https://api.github.com/users/filipesilva/repos","events_url":"https://api.github.com/users/filipesilva/events{/privacy}","received_events_url":"https://api.github.com/users/filipesilva/received_events","type":"User","site_admin":false}],"milestone":null,"comments":9,"created_at":"2016-09-18T20:51:59Z","updated_at":"2016-10-10T22:01:10Z","closed_at":"2016-10-10T22:01:10Z","body":"**Karma throws errors when using custom source directory**\r\n\r\n* Tests can't find jasmine methods when using custom source directory.\r\n* Tests run well with default source directory.\r\n\r\n**My cli version (running under Windows 10)**\r\n```\r\nC:\\>ng version\r\nangular-cli: 1.0.0-beta.14\r\nnode: 6.6.0\r\nos: win32 x64\r\n```\r\n\r\n**Error log:**\r\n```\r\nC:\\demo>ng test\r\n18 09 2016 22:44:34.517:WARN [karma]: No captured browser, open http://localhost:9876/\r\n\r\nWARNING in ./~/@angular/core/src/linker/system_js_ng_module_factory_loader.js\r\n45:15 Critical dependency: the request of a dependency is an expression\r\n\r\nWARNING in ./~/@angular/core/src/linker/system_js_ng_module_factory_loader.js\r\n57:15 Critical dependency: the request of a dependency is an expression\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.spec.ts:6:0\r\nCannot find name 'describe'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.spec.ts:7:2\r\nCannot find name 'beforeEach'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.spec.ts:15:2\r\nCannot find name 'it'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.spec.ts:18:4\r\nCannot find name 'expect'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.spec.ts:21:2\r\nCannot find name 'it'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.spec.ts:24:4\r\nCannot find name 'expect'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.spec.ts:27:2\r\nCannot find name 'it'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.spec.ts:31:4\r\nCannot find name 'expect'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.ts:5:12\r\nCannot find name 'require'.\r\n\r\nERROR in [default] C:\\demo\\aaa\\bbb\\ccc\\app\\app.component.ts:6:11\r\nCannot find name 'require'.\r\n18 09 2016 22:44:34.538:INFO [karma]: Karma v1.2.0 server started at http://localhost:9876/\r\n18 09 2016 22:44:34.538:INFO [launcher]: Launching browser Chrome with unlimited concurrency\r\n18 09 2016 22:44:34.554:INFO [launcher]: Starting browser Chrome\r\n18 09 2016 22:44:35.985:INFO [Chrome 53.0.2785 (Windows 10 0.0.0)]: Connected on socket /#yDvYLk6xqHJ7A9jPAAAA with id 65295348\r\nChrome 53.0.2785 (Windows 10 0.0.0): Executed 3 of 3 SUCCESS (0.211 secs / 0.192 secs)\r\n```\r\n\r\n**How to reproduce:**\r\n```\r\nC:\\>ng new -sd aaa/bbb/ccc demo\r\ninstalling ng2\r\n  create README.md\r\n  create aaa\\bbb\\ccc\\app\\app.component.css\r\n  create aaa\\bbb\\ccc\\app\\app.component.html\r\n  create aaa\\bbb\\ccc\\app\\app.component.spec.ts\r\n  create aaa\\bbb\\ccc\\app\\app.component.ts\r\n  create aaa\\bbb\\ccc\\app\\app.module.ts\r\n  create aaa\\bbb\\ccc\\app\\index.ts\r\n  create aaa\\bbb\\ccc\\app\\shared\\index.ts\r\n  create aaa\\bbb\\ccc\\environments\\environment.prod.ts\r\n  create aaa\\bbb\\ccc\\environments\\environment.ts\r\n  create aaa\\bbb\\ccc\\favicon.ico\r\n  create aaa\\bbb\\ccc\\index.html\r\n  create aaa\\bbb\\ccc\\main.ts\r\n  create aaa\\bbb\\ccc\\polyfills.ts\r\n  create aaa\\bbb\\ccc\\styles.css\r\n  create aaa\\bbb\\ccc\\test.ts\r\n  create aaa\\bbb\\ccc\\tsconfig.json\r\n  create aaa\\bbb\\ccc\\typings.d.ts\r\n  create angular-cli.json\r\n  create e2e\\app.e2e-spec.ts\r\n  create e2e\\app.po.ts\r\n  create e2e\\tsconfig.json\r\n  create .gitignore\r\n  create karma.conf.js\r\n  create package.json\r\n  create protractor.conf.js\r\n  create tslint.json\r\nSuccessfully initialized git.\r\nInstalling packages for tooling via npm.\r\nInstalled packages for tooling via npm.\r\n\r\nC:\\>cd demo\r\n\r\nC:\\demo>ng test\r\n\r\n```\r\n\r\n"}}
{"actor":{"display_login":"filipesilva"}}