How to do it...

Follow these steps to run the test case in debug mode:

  1. Open the file /static/tests/colorpicker_tests.js, and update the test QUnit.test with QUnit.only, like this:
...
QUnit.only('int_color field test cases', function (assert) {
...

  1. Add the debug parameter in the createView function, as follows:
var form = testUtils.createView({
View: FormView,
model: 'book',
data: this.data,
arch: '<form string="Books">' +
'<group>' +
'<field name="name"/>' +
'<field name="color" widget="int_color"/>' +
'</group>' +
'</form>',
res_id: 1,
viewOptions: {
mode: 'edit',
},
debug:1
});

Open the developer mode and open the drop-down menu by clicking on the bug icon on the top menu, then click on Run JS tests. This will open the QUnit suit.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset