Skip to content

Commit

Permalink
first step at share panel tests
Browse files Browse the repository at this point in the history
  • Loading branch information
briehl committed Jul 15, 2020
1 parent f4432b0 commit 609f2de
Showing 1 changed file with 31 additions and 4 deletions.
35 changes: 31 additions & 4 deletions test/unit/spec/narrative_core/kbaseNarrativeSharePanel-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,38 @@
/*jslint white: true*/
define([
'jquery',
'kbaseNarrativeSharePanel'
], function($, Widget) {
describe('Test the kbaseNarrativeSharePanel widget', function() {
it('Should do things', function() {
'kbaseNarrativeSharePanel',
'base/js/namespace',
'kbaseNarrative',
], function($, KBaseNarrativeSharePanel, Jupyter, Narrative) {
describe('Test the kbaseNarrativeSharePanel widget', () => {
let sharePanel;
const $div = $('div');
const workspaceId = 12345;

beforeEach(function() {
jasmine.Ajax.install();
Jupyter.narrative = new Narrative();
Jupyter.narrative.userId = 'narrativetest';
Jupyter.narrative.narrController = {
uiModeIs: p => false
};
Jupyter.narrative.getAuthToken = () => { return 'NotARealToken!' };

sharePanel = new KBaseNarrativeSharePanel($div, { wsId: workspaceId });
});

afterEach(() => {
jasmine.Ajax.uninstall();
$div.empty();
});

it('Should build a widget', () => {
expect(KBaseNarrativeSharePanel).toBeDefined();
expect(sharePanel).toBeDefined();
});

it('Should ')

});
});

0 comments on commit 609f2de

Please sign in to comment.