summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2017-04-24 13:47:46 +0200
committerGitHub <noreply@github.com>2017-04-24 13:47:46 +0200
commit97c27395aaddf974ad341f30e43b8554778c4ffe (patch)
treee2fa9edeba318009d8f0ef4155f2bcb40f5e0201 /core
parent42e805f0578b95206fdddabfe6234b0880c27b1e (diff)
parent2317d7bb497cce3e5731dd43e2e69b9d3e780bb0 (diff)
downloadnextcloud-server-97c27395aaddf974ad341f30e43b8554778c4ffe.tar.gz
nextcloud-server-97c27395aaddf974ad341f30e43b8554778c4ffe.zip
Merge pull request #4458 from nextcloud/fix/sinon-stub-deprecation-warnings
Fix sinon.stub deprecation warnings
Diffstat (limited to 'core')
-rw-r--r--core/js/tests/specs/jquery.avatarSpec.js2
-rw-r--r--core/js/tests/specs/sharedialogviewSpec.js4
2 files changed, 3 insertions, 3 deletions
diff --git a/core/js/tests/specs/jquery.avatarSpec.js b/core/js/tests/specs/jquery.avatarSpec.js
index 9bb10c41be7..dab78500d0b 100644
--- a/core/js/tests/specs/jquery.avatarSpec.js
+++ b/core/js/tests/specs/jquery.avatarSpec.js
@@ -186,7 +186,7 @@ describe('jquery.avatar tests', function() {
});
it('with ie8 fix', function() {
- sinon.stub(Math, 'random', function() {
+ sinon.stub(Math, 'random').callsFake(function() {
return 0.5;
});
diff --git a/core/js/tests/specs/sharedialogviewSpec.js b/core/js/tests/specs/sharedialogviewSpec.js
index 307adea85ff..95349bc4875 100644
--- a/core/js/tests/specs/sharedialogviewSpec.js
+++ b/core/js/tests/specs/sharedialogviewSpec.js
@@ -19,7 +19,7 @@
*
*/
-/* global oc_appconfig */
+/* global oc_appconfig, sinon */
describe('OC.Share.ShareDialogView', function() {
var $container;
var oldAppConfig;
@@ -90,7 +90,7 @@ describe('OC.Share.ShareDialogView', function() {
linkShare: {isLinkShare: false}
});
- autocompleteStub = sinon.stub($.fn, 'autocomplete', function() {
+ autocompleteStub = sinon.stub($.fn, 'autocomplete').callsFake(function() {
// dummy container with the expected attributes
if (!$(this).length) {
// simulate the real autocomplete that returns