diff options
| author | Martin Geubelle <mge@odoo.com> | 2017-11-23 18:15:15 +0100 |
|---|---|---|
| committer | Martin Geubelle <mge@odoo.com> | 2017-11-27 14:01:50 +0100 |
| commit | 76ba56e60db87f2fa574b37974ee4f48b3fd94b6 (patch) | |
| tree | 72b9e993f25ae9ca1a8d0f6765d2ffcac8eac8fc /addons/web/static/tests | |
| parent | 2fbbf0b1ffd740b13778df5e53369737055dd9c2 (diff) | |
[FIX] web: List: handle custom class on button
It should be possible to set a custom class on a button in the list view.
Closes #20620
Diffstat (limited to 'addons/web/static/tests')
| -rw-r--r-- | addons/web/static/tests/views/list_tests.js | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/addons/web/static/tests/views/list_tests.js b/addons/web/static/tests/views/list_tests.js index 22399961285..5f003dfac61 100644 --- a/addons/web/static/tests/views/list_tests.js +++ b/addons/web/static/tests/views/list_tests.js @@ -1088,7 +1088,7 @@ QUnit.module('Views', { }); QUnit.test('can display button in edit mode', function (assert) { - assert.expect(1); + assert.expect(2); var list = createView({ View: ListView, @@ -1096,10 +1096,11 @@ QUnit.module('Views', { data: this.data, arch: '<tree editable="bottom">' + '<field name="foo"/>' + - '<button name="notafield" type="object" icon="fa-asterisk"/>' + + '<button name="notafield" type="object" icon="fa-asterisk" class="o_yeah"/>' + '</tree>', }); assert.ok(list.$('tbody button').length, "should have a button"); + assert.ok(list.$('tbody button').hasClass('o_yeah'), "class should be set on the button"); list.destroy(); }); |
