2
0
mirror of https://github.com/tenrok/axios.git synced 2026-05-24 14:04:14 +03:00

Removing deprecated success/error aliases

closes #57
This commit is contained in:
mzabriskie
2015-04-08 14:44:41 -06:00
parent 8c1694e821
commit 0e33680f40
3 changed files with 0 additions and 54 deletions
-2
View File
@@ -15,8 +15,6 @@ describe('api', function () {
expect(typeof promise.then).toEqual('function');
expect(typeof promise.catch).toEqual('function');
expect(typeof promise.success).toEqual('function');
expect(typeof promise.error).toEqual('function');
});
it('should have defaults', function () {
-31
View File
@@ -37,37 +37,6 @@ describe('promise', function () {
}, 0);
});
it('should provide verbose arguments to success', function (done) {
var request, data, status, headers, config;
axios({
url: '/foo'
}).success(function (d, s, h, c) {
data = d;
status = s;
headers = h;
config = c;
fulfilled = true;
});
setTimeout(function () {
request = jasmine.Ajax.requests.mostRecent();
request.respondWith({
status: 200,
responseText: '{"hello":"world"}'
});
setTimeout(function () {
expect(data.hello).toEqual('world');
expect(status).toBe(200);
expect(headers['content-type']).toEqual('application/json');
expect(config.url).toEqual('/foo');
done();
}, 0);
}, 0);
});
it('should support all', function (done) {
var fulfilled = false;