mirror of
https://github.com/tenrok/axios.git
synced 2026-06-02 16:04:10 +03:00
Add manual tests
This would help testing browser support.
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
An alert should be shown with the <code>{"name":"axios"}</code>
|
||||
|
||||
<script src="promise.js"></script>
|
||||
<script src="../../dist/axios.js"></script>
|
||||
<script>
|
||||
axios.get('./fixture.json').then(function(response) {
|
||||
console.log(response);
|
||||
alert(JSON.stringify(response.data));
|
||||
alert('response headers:\n\n' + JSON.stringify(response.headers));
|
||||
}, function(err) { console.log(err) });
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
An alert should be shown with <code>{"status":"ok"}</code>
|
||||
|
||||
<script src="promise.js"></script>
|
||||
<script src="../../dist/axios.js"></script>
|
||||
<script>
|
||||
axios.get('http://cors-test.appspot.com/test').then(function(response) {
|
||||
alert(JSON.stringify(response.data));
|
||||
alert('response headers:\n\n' + JSON.stringify(response.headers));
|
||||
}, function(err) { console.log(err) });
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"name": "axios"
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user