test: make security testcase internet explorer compatible
Internet Explorer does not support the 'class Testclass {}' notation,
and tests are not compiled using babel.
closes #1497
This commit is contained in:
+8
-3
@@ -11,11 +11,16 @@ describe('security issues', function() {
|
||||
});
|
||||
|
||||
it('should allow prototype properties that are not constructors', function() {
|
||||
class TestClass {
|
||||
get abc() {
|
||||
function TestClass() {
|
||||
}
|
||||
|
||||
Object.defineProperty(TestClass.prototype, 'abc', {
|
||||
get: function() {
|
||||
return 'xyz';
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
shouldCompileTo('{{#with this as |obj|}}{{obj.abc}}{{/with}}',
|
||||
new TestClass(), 'xyz');
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user