Fix jsunit tests

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl 2022-08-31 19:05:15 +02:00
parent b6a6802857
commit 6ad600ea8a
No known key found for this signature in database
GPG Key ID: 4C614C6ED2CDE6DF
7 changed files with 16 additions and 16 deletions

View File

@ -26,7 +26,7 @@ describe('OCA.Comments.FilesPlugin tests', function() {
var testFiles;
beforeEach(function() {
var $content = $('<div id="content"></div>');
var $content = $('<div id="app-content"></div>');
$('#testArea').append($content);
// dummy file list
var $div = $(
@ -36,7 +36,7 @@ describe('OCA.Comments.FilesPlugin tests', function() {
'<tbody class="files-fileList"></tbody>' +
'</table>' +
'</div>');
$('#content').append($div);
$('#app-content').append($div);
fileList = new OCA.Files.FileList($div);
OCA.Comments.FilesPlugin.attach(fileList);

View File

@ -28,7 +28,7 @@ describe('OCA.Files.FavoritesFileList tests', function() {
beforeEach(function() {
// init parameters and test table elements
$('#testArea').append(
'<div id="app-content-container">' +
'<div id="app-content">' +
// init horrible parameters
'<input type="hidden" id="permissions" value="31"></input>' +
// dummy controls
@ -60,7 +60,7 @@ describe('OCA.Files.FavoritesFileList tests', function() {
beforeEach(function() {
fileList = new OCA.Files.FavoritesFileList(
$('#app-content-container')
$('#app-content')
);
OCA.Files.FavoritesPlugin.attach(fileList);

View File

@ -27,7 +27,7 @@ describe('OCA.Files.TagsPlugin tests', function() {
var testFiles;
beforeEach(function() {
var $content = $('<div id="content"></div>');
var $content = $('<div id="app-content"></div>');
$('#testArea').append($content);
// dummy file list
var $div = $(
@ -37,7 +37,7 @@ describe('OCA.Files.TagsPlugin tests', function() {
'<tbody class="files-fileList"></tbody>' +
'</table>' +
'</div>');
$('#content').append($div);
$('#app-content').append($div);
fileList = new OCA.Files.FileList($div);
OCA.Files.TagsPlugin.attach(fileList);

View File

@ -31,7 +31,7 @@ describe('OCA.Files_External.FileList tests', function() {
// init parameters and test table elements
$('#testArea').append(
'<div id="app-content-container">' +
'<div id="app-content">' +
// init horrible parameters
'<input type="hidden" id="permissions" value="31"></input>' +
// dummy controls
@ -77,7 +77,7 @@ describe('OCA.Files_External.FileList tests', function() {
beforeEach(function() {
fileList = new OCA.Files_External.FileList(
$('#app-content-container')
$('#app-content')
);
reloading = fileList.reload();

View File

@ -41,7 +41,7 @@ describe('OCA.Sharing.Util tests', function() {
}
beforeEach(function() {
var $content = $('<div id="content"></div>');
var $content = $('<div id="app-content"></div>');
$('#testArea').append($content);
// dummy file list
var $div = $(
@ -51,7 +51,7 @@ describe('OCA.Sharing.Util tests', function() {
'<tbody class="files-fileList"></tbody>' +
'</table>' +
'</div>');
$('#content').append($div);
$('#app-content').append($div);
var fileActions = new OCA.Files.FileActions();
fileList = new OCA.Files.FileList(

View File

@ -42,7 +42,7 @@ describe('OCA.Trashbin.FileList tests', function () {
// init parameters and test table elements
$('#testArea').append(
'<div id="app-content-trashbin">' +
'<div id="app-content">' +
// set this but it shouldn't be used (could be the one from the
// files app)
'<input type="hidden" id="permissions" value="31"></input>' +
@ -105,7 +105,7 @@ describe('OCA.Trashbin.FileList tests', function () {
// register file actions like the trashbin App does
var fileActions = OCA.Trashbin.App._createFileActions(fileList);
fileList = new OCA.Trashbin.FileList(
$('#app-content-trashbin'), {
$('#app-content'), {
fileActions: fileActions,
multiSelectMenu: [{
name: 'restore',

View File

@ -28,7 +28,7 @@ describe('OCA.SystemTags.FileList tests', function() {
beforeEach(function() {
// init parameters and test table elements
$('#testArea').append(
'<div id="app-content-container">' +
'<div id="app-content">' +
// init horrible parameters
'<input type="hidden" id="permissions" value="31"></input>' +
'<div class="files-controls"></div>' +
@ -77,7 +77,7 @@ describe('OCA.SystemTags.FileList tests', function() {
]);
fileList = new OCA.SystemTags.FileList(
$('#app-content-container'), {
$('#app-content'), {
systemTagIds: []
}
);
@ -167,7 +167,7 @@ describe('OCA.SystemTags.FileList tests', function() {
it('renders empty message when no tags were set', function() {
fileList = new OCA.SystemTags.FileList(
$('#app-content-container'), {
$('#app-content'), {
systemTagIds: []
}
);
@ -181,7 +181,7 @@ describe('OCA.SystemTags.FileList tests', function() {
it('render files', function(done) {
fileList = new OCA.SystemTags.FileList(
$('#app-content-container'), {
$('#app-content'), {
systemTagIds: ['123', '456']
}
);