seitime-frappe/frappe/tests/ui/test_linked_with.js
Faris Ansari 67277507f0 [hotfix] Linked with and List item click (#3803)
* [hotfix] Linked with and List item click

* Run a single test using Test Runner

* Add test for Linked With

* [minor] List view fixes
2017-07-28 14:30:18 +05:30

19 lines
No EOL
609 B
JavaScript

QUnit.module('form');
QUnit.test("Test Linked With", function(assert) {
assert.expect(2);
const done = assert.async();
frappe.run_serially([
() => frappe.set_route('Form', 'Module Def', 'Contacts'),
() => frappe.tests.click_page_head_item('Menu'),
() => frappe.tests.click_dropdown_item('Links'),
() => frappe.timeout(4),
() => {
assert.equal(cur_dialog.title, 'Linked With', 'Linked with dialog is opened');
const link_tables_count = cur_dialog.$wrapper.find('.list-item-table').length;
assert.equal(link_tables_count, 2, 'Two DocTypes are linked with Contacts');
},
done
]);
});