mirror of
https://github.com/silkimen/cordova-plugin-advanced-http.git
synced 2024-10-06 09:12:13 +08:00
fix #344: "disableRedirect" removed since 3.0, use "setFollowRedirect"
This commit is contained in:
parent
a72bf758c6
commit
b32dfc7143
@ -309,7 +309,7 @@ const tests = [
|
||||
{
|
||||
description: 'should not follow 302 redirect when following redirects is disabled',
|
||||
expected: 'rejected: {"status": 302, ...',
|
||||
before: function (resolve, reject) { cordova.plugin.http.disableRedirect(true, resolve, reject) },
|
||||
before: function (resolve, reject) { cordova.plugin.http.setFollowRedirect(false); resolve(); },
|
||||
func: function (resolve, reject) { cordova.plugin.http.get('http://httpbingo.org/redirect-to?url=http://httpbin.org/anything', {}, {}, resolve, reject); },
|
||||
validationFunc: function (driver, result) {
|
||||
result.type.should.be.equal('rejected');
|
||||
|
Loading…
Reference in New Issue
Block a user