This error usually occurs if the browser does not have new features. Can be easily fixed by including polyfills.
import 'core-js/es6/symbol'; import 'core-js/es6/object'; import 'core-js/es6/function'; import 'core-js/es6/parse-int'; import 'core-js/es6/parse-float'; import 'core-js/es6/number'; import 'core-js/es6/math'; import 'core-js/es6/string'; import 'core-js/es6/date'; import 'core-js/es6/array'; import 'core-js/es6/regexp'; import 'core-js/es6/map'; import 'core-js/es6/weak-map'; import 'core-js/es6/set';
To your vendorβs file or a file that will start your tests if you switched to karma.config.js
browsers: ['Chrome'] to browsers: ['PhantomJS']
Or get this error after running ng test
source share