diff options
Diffstat (limited to 'apps/files/tests/js/fileactionsSpec.js')
-rw-r--r-- | apps/files/tests/js/fileactionsSpec.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/apps/files/tests/js/fileactionsSpec.js b/apps/files/tests/js/fileactionsSpec.js index cc12bfc7642..536688d291d 100644 --- a/apps/files/tests/js/fileactionsSpec.js +++ b/apps/files/tests/js/fileactionsSpec.js @@ -35,7 +35,7 @@ describe('OCA.Files.FileActions tests', function() { var $body = $('#testArea'); $body.append('<input type="hidden" id="dir" value="/subdir"></input>'); $body.append('<input type="hidden" id="permissions" value="31"></input>'); - $body.append('<table id="filestable" class="list-container view-grid"><tbody id="fileList"></tbody></table>'); + $body.append('<table class="files-filestable list-container view-grid"><tbody class="files-fileList"></tbody></table>'); // dummy files table fileActions = new OCA.Files.FileActions(); fileActions.registerAction({ @@ -72,7 +72,7 @@ describe('OCA.Files.FileActions tests', function() { fileList.destroy(); fileList = undefined; clock.restore(); - $('#dir, #permissions, #filestable').remove(); + $('#dir, #permissions, .files-filestable').remove(); }); it('calling clear() clears file actions', function() { fileActions.clear(); @@ -307,6 +307,8 @@ describe('OCA.Files.FileActions tests', function() { }); it('passes context to action handler', function() { var notifyUpdateListenersSpy = sinon.spy(fileList.fileActions, '_notifyUpdateListeners'); + expect($tr.length).toEqual(1); + expect($tr.find('.action-test').length).toEqual(1); $tr.find('.action-test').click(); expect(actionStub.calledOnce).toEqual(true); expect(actionStub.getCall(0).args[0]).toEqual('testName.txt'); |