mirror of
https://github.com/jupyter/notebook.git
synced 2024-12-27 04:20:22 +08:00
Removed js test utils commit and rebased with master.
Also add test to see if selection widgets are atleast displayed.
This commit is contained in:
parent
4ec03f00d9
commit
df2c5d7d06
@ -714,7 +714,7 @@ casper.notebook_test(function () {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Test selection widget /////////////////////////////////////////////////
|
// Test selection widget /////////////////////////////////////////////////
|
||||||
var combo_selector = '.widget-area .widget-subarea .widget-hbox-single .btn-group .widget-combo-button'
|
var combo_selector = '.widget-area .widget-subarea .widget-hbox-single .btn-group .widget-combo-btn'
|
||||||
var multibtn_selector = '.widget-area .widget-subarea .widget-hbox-single .btn-group[data-toggle="buttons-radio"]'
|
var multibtn_selector = '.widget-area .widget-subarea .widget-hbox-single .btn-group[data-toggle="buttons-radio"]'
|
||||||
var radio_selector = '.widget-area .widget-subarea .widget-hbox .vbox'
|
var radio_selector = '.widget-area .widget-subarea .widget-hbox .vbox'
|
||||||
var list_selector = '.widget-area .widget-subarea .widget-hbox .widget-listbox'
|
var list_selector = '.widget-area .widget-subarea .widget-hbox .widget-listbox'
|
||||||
@ -734,13 +734,11 @@ casper.notebook_test(function () {
|
|||||||
|
|
||||||
this.test.assert(multibtn_state == state, 'Multibutton correct state (' + state + '), ' + test_mssage);
|
this.test.assert(multibtn_state == state, 'Multibutton correct state (' + state + '), ' + test_mssage);
|
||||||
this.test.assert(radio_state == state, 'Radio correct state (' + state + '), ' + test_mssage);
|
this.test.assert(radio_state == state, 'Radio correct state (' + state + '), ' + test_mssage);
|
||||||
this.test.assert(list_state == state, 'ListBox correct state (' + state + '), ' + test_mssage);
|
this.test.assert(list_state == state, 'Listbox correct state (' + state + '), ' + test_mssage);
|
||||||
this.test.assert(combo_state == state, 'ComboBox correct state (' + state + '), ' + test_mssage);
|
this.test.assert(combo_state == state, 'Combobox correct state (' + state + '), ' + test_mssage);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
selection_index = this.append_cell(
|
selection_index = this.append_cell(
|
||||||
'selection = widgets.SelectionWidget(values=["' + selection_values + '"[i] for i in range(4)])\n' +
|
'selection = widgets.SelectionWidget(values=["' + selection_values + '"[i] for i in range(4)])\n' +
|
||||||
'display(selection)\n' +
|
'display(selection)\n' +
|
||||||
@ -752,8 +750,21 @@ casper.notebook_test(function () {
|
|||||||
this.test.assert(this.get_output_cell(index).text == 'Success\n',
|
this.test.assert(this.get_output_cell(index).text == 'Success\n',
|
||||||
'Create selection cell executed with correct output. (1)');
|
'Create selection cell executed with correct output. (1)');
|
||||||
|
|
||||||
this.test.assert(,
|
this.test.assert(this.cell_element_exists(index,
|
||||||
'');
|
'.widget-area .widget-subarea'),
|
||||||
|
'Widget subarea exists.');
|
||||||
|
|
||||||
|
// this.test.assert(this.cell_element_exists(index, combo_selector),
|
||||||
|
// 'Widget combobox exists.');
|
||||||
|
|
||||||
|
this.test.assert(this.cell_element_exists(index, multibtn_selector),
|
||||||
|
'Widget multibutton exists.');
|
||||||
|
|
||||||
|
this.test.assert(this.cell_element_exists(index, radio_selector),
|
||||||
|
'Widget radio buttons exists.');
|
||||||
|
|
||||||
|
this.test.assert(this.cell_element_exists(index, list_selector),
|
||||||
|
'Widget list exists.');
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user