init
This commit is contained in:
32
test/mocks.js
Normal file
32
test/mocks.js
Normal file
@@ -0,0 +1,32 @@
|
||||
var timeout = 200;
|
||||
$(function () {
|
||||
|
||||
$.mockjaxSettings.responseTime = 50;
|
||||
|
||||
$.mockjax({
|
||||
url: 'post.php',
|
||||
responseText: {
|
||||
success: true
|
||||
}
|
||||
});
|
||||
|
||||
$.mockjax({
|
||||
url: 'error.php',
|
||||
status: 500,
|
||||
statusText: 'Internal Server Error',
|
||||
responseText: 'customtext'
|
||||
});
|
||||
|
||||
$.mockjax({
|
||||
url: 'post-resp.php',
|
||||
response: function(settings) {
|
||||
this.responseText = settings;
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
// usefull functions
|
||||
|
||||
function tip(e) {
|
||||
return e.data('editableContainer').tip();
|
||||
}
|
Reference in New Issue
Block a user