mirror of
https://github.com/tenrok/axios.git
synced 2026-05-15 11:59:42 +03:00
Change syntax to see if build passes (#2488)
* Change syntax to see if build passes * Test commit * Test with node 10 * Test adding all browsers in travis * remove other browsers when running on travis
This commit is contained in:
committed by
Felipe Martins
parent
189b34c45a
commit
494d817314
+1
-1
@@ -2,7 +2,7 @@ services:
|
||||
- xvfb
|
||||
language: node_js
|
||||
node_js:
|
||||
- node
|
||||
- 10
|
||||
email:
|
||||
on_failure: change
|
||||
on_success: never
|
||||
|
||||
@@ -10,7 +10,8 @@ describe('helpers::isURLSameOrigin', function () {
|
||||
});
|
||||
|
||||
it('should detect XSS scripts on a same origin request', function () {
|
||||
expect(() => { isURLSameOrigin('https://github.com/axios/axios?<script>alert("hello")</script>'); })
|
||||
.toThrowError(Error, 'URL contains XSS injection attempt')
|
||||
})
|
||||
expect(function() {
|
||||
isURLSameOrigin('https://github.com/axios/axios?<script>alert("hello")</script>');
|
||||
}).toThrowError(Error, 'URL contains XSS injection attempt')
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user