Skip to content

Commit 4d55921

Browse files
committed
added amd-loader
1 parent 8fba7da commit 4d55921

18 files changed

+85513
-92627
lines changed

apps/codelab/src/app/components/angular-test-runner/angular-test-runner.component.ts

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,10 @@ export class SimpleAngularTestRunnerComponent
123123
{
124124
id: 'testing',
125125
url: '/assets/runner',
126+
},
127+
({ evalJs }) => {
128+
// evalJs(this.scriptLoaderService.getScript('shim'));
129+
// evalJs(this.scriptLoaderService.getScript('zone'));
126130
}
127131
);
128132

@@ -134,18 +138,20 @@ export class SimpleAngularTestRunnerComponent
134138
sandbox.evalJs(this.scriptLoaderService.getScript('chai'));
135139
sandbox.evalJs(this.scriptLoaderService.getScript('mocha'));
136140
sandbox.evalJs(this.scriptLoaderService.getScript('test-bootstrap'));
137-
sandbox.evalJs(this.scriptLoaderService.getScript('shim'));
138-
sandbox.evalJs(this.scriptLoaderService.getScript('zone'));
141+
// sandbox.evalJs(this.scriptLoaderService.getScript('shim'));
142+
// sandbox.evalJs(this.scriptLoaderService.getScript('zone'));
139143
// sandbox.evalJs(this.scriptLoaderService.getScript('system-config'));
140-
sandbox.evalJs(this.scriptLoaderService.getScript('ng-bundle'));
144+
// sandbox.evalJs(this.scriptLoaderService.getScript('ng-bundle'));
141145

142146
this.subscription = this.changedFilesSubject.subscribe((files) => {
147+
addMetaInformation(sandbox, this.code);
148+
149+
143150
const hasErrors = Object.entries(files)
144-
.filter(([path]) => path.match(/\.js$/))
151+
.filter(([path]) => path.match(/\.js$/) && !path.startsWith('code'))
145152
.map(([path, code]) => {
146153
try {
147154
sandbox.evalJs(`console.log('I remove modul')`);
148-
addMetaInformation(sandbox, this.code);
149155
sandbox.evalJs(code);
150156
} catch (e) {
151157
console.groupCollapsed(e.message);

0 commit comments

Comments
 (0)