summaryrefslogtreecommitdiff
path: root/addons/point_of_sale/static/tests/unit/test_ChromeWidgets.js
diff options
context:
space:
mode:
authorJoseph Caburnay <jcb@odoo.com>2020-07-09 12:07:14 +0000
committerJoseph Caburnay <jcb@odoo.com>2020-08-05 13:35:08 +0000
commit9ea0aca6ea30fe42e1a7e0a4eaeb79f92a521152 (patch)
treeb3c969ef00f0bbc637d94c124202a96887df450a /addons/point_of_sale/static/tests/unit/test_ChromeWidgets.js
parent71f719a61ea34252abdc9f1b2fb2caf8e62c7917 (diff)
[IMP] point_of_sale,pos_*: top bar improvements and ticket list
The following changes are made in this task: 1. Remove order tabs and replace with ticket list. 2. Top bar color change. 3. Search bar in the product screen is moved in the top bar. 4. List of sub-categories are now in the same line as the category breadcrumbs. closes odoo/odoo#55100 Task-id: 2276678 Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
Diffstat (limited to 'addons/point_of_sale/static/tests/unit/test_ChromeWidgets.js')
-rw-r--r--addons/point_of_sale/static/tests/unit/test_ChromeWidgets.js47
1 files changed, 0 insertions, 47 deletions
diff --git a/addons/point_of_sale/static/tests/unit/test_ChromeWidgets.js b/addons/point_of_sale/static/tests/unit/test_ChromeWidgets.js
index c1ad31804e6..a0df97fdbd4 100644
--- a/addons/point_of_sale/static/tests/unit/test_ChromeWidgets.js
+++ b/addons/point_of_sale/static/tests/unit/test_ChromeWidgets.js
@@ -49,53 +49,6 @@ odoo.define('point_of_sale.tests.ChromeWidgets', function (require) {
parent.destroy();
});
- QUnit.test('OrderSelector', async function (assert) {
- assert.expect(4);
-
- class Parent extends PopupControllerMixin(PosComponent) {}
- Parent.env = makePosTestEnv();
- Parent.env.chrome = new owl.Context({ showOrderSelector: true });
- Parent.template = xml/* html */ `
- <div>
- <OrderSelector></OrderSelector>
- <t t-if="popup.isShown" t-component="popup.component" t-props="popupProps" t-key="popup.name" />
- </div>
- `;
-
- const pos = Parent.env.pos;
-
- const parent = new Parent();
- await parent.mount(testUtils.prepareTarget());
-
- const plusButton = parent.el.querySelector('.neworder-button');
- const minusButton = parent.el.querySelector('.deleteorder-button');
-
- await testUtils.dom.click(plusButton);
- await testUtils.nextTick();
- assert.strictEqual(2, parent.el.querySelectorAll('.order-sequence').length);
- await testUtils.dom.click(minusButton);
- await testUtils.nextTick();
- assert.strictEqual(1, parent.el.querySelectorAll('.order-sequence').length);
-
- const product = Object.values(pos.db.product_by_id)[0];
- pos.get_order().add_product(product);
-
- // try deleting the order with orderline
- await testUtils.dom.click(minusButton);
- await testUtils.nextTick();
-
- // confirm popup should appear
- assert.ok(parent.el.querySelector('.popup'));
- // confirm deletion
- await testUtils.dom.click(parent.el.querySelector('.confirm'));
- await testUtils.nextTick();
- // there should be new order created
- assert.strictEqual(1, parent.el.querySelectorAll('.order-sequence').length);
-
- parent.unmount();
- parent.destroy();
- });
-
QUnit.test('SyncNotification', async function (assert) {
assert.expect(5);