Skip to content

Commit

Permalink
reverting expand row on click
Browse files Browse the repository at this point in the history
  • Loading branch information
dsheiko committed Dec 19, 2018
1 parent c687813 commit cb73bdc
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 9 deletions.
1 change: 1 addition & 0 deletions app/constant/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ exports.E_RUNTIME_TEST_MILESTONE = "runtimeTestMilestone";
exports.E_RUNTIME_TEST_ERROR = "runtimeTestError";
exports.E_SHOW_CONFIRM_DIALOG = "showConfirmDialog";
exports.E_CONFIRM_DIALOG_VALUE = "confirmDialogValue";
exports.E_ENTITY_CREATED = "entityCreated";

exports.E_FILE_NAVIGATOR_UPDATED = "fileNavigatorUpdated";
exports.E_WATCH_FILE_NAVIGATOR = "watchFileNavigator";
Expand Down
2 changes: 1 addition & 1 deletion src/__e2e__/lib/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ exports.MODAL_NEW_PROJECT = `.c-new-project-modal`;
exports.MODAL_NEW_SUITE = `.c-new-suite-modal`;
exports.ACTIVE_EDITABLE_ROW = `.ant-form.ant-form-horizontal.cell-form`;
exports.EDITABLE_ROW_SUBMIT_BTN = `.ant-btn.ant-btn-primary`;
exports.EDITABLE_ROW_EXPAND_ICON = `.ant-table-row-expand-icon.ant-table-row-collapsed`;
exports.EDITABLE_ROW_EXPAND_ICON = `.ant-table-row-expand-icon.ant-table-row-collapsed`; // ant-table-row-expand-icon ant-table-row-expanded
exports.MENU_ITEM_DISABLED_CLS = "ant-menu-item-disabled";
4 changes: 3 additions & 1 deletion src/__e2e__/specs/mainNav.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ describe( "Main Navigation", () => {
describe( "When no project is open", () => {

test( "check items availability", async () => {

// update component
await ctx.client.moveToObject( "#cMainMenuFile" );

await ctx.expectMenuItemsAvailable({
"#cMainMenuNewProject": true,
"#cMainMenuNewSuite": false,
Expand Down
14 changes: 9 additions & 5 deletions src/__e2e__/specs/newProject.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,10 @@ describe( "New Project", () => {
});

test( "expand group", async() => {
await ctx.client.click( `#cGroupTable ${ S.EDITABLE_ROW_EXPAND_ICON }` );
await ctx.screenshot( "group-expanded" );
if ( !await ctx.client.isExisting( `#cTestTableAddBtn` ) ) {
await ctx.client.click( `#cGroupTable ${ S.EDITABLE_ROW_EXPAND_ICON }` );
await ctx.screenshot( "group-expanded" );
}
});

test( "add a test", async() => {
Expand All @@ -136,9 +138,11 @@ describe( "New Project", () => {
});

test( "expand test", async() => {
await ctx.client.click( `#cTestTable ${ S.EDITABLE_ROW_EXPAND_ICON }` );
await ctx.screenshot( "test-expanded" );
await ctx.client.pause( 200 );
if ( !await ctx.client.isExisting( `#cCommandTableAddBtn` ) ) {
await ctx.client.click( `#cTestTable ${ S.EDITABLE_ROW_EXPAND_ICON }` );
await ctx.screenshot( "test-expanded" );
await ctx.client.pause( 200 );
}
});

test( "add a command", async() => {
Expand Down
1 change: 0 additions & 1 deletion src/component/AppLayout/Main/GroupTable.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ export class GroupTable extends AbstractEditableTable {
dataSource={ groups }
columns={this.columns}
pagination={false}
expandRowByClick={ true }
onExpand={this.onExpand}
expandedRowRender={ this.renderExpandedTable }
footer={() => ( <Button
Expand Down
1 change: 0 additions & 1 deletion src/component/AppLayout/Main/GroupTable/TestTable.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ export class TestTable extends AbstractEditableTable {
rowClassName={ this.onRowClassName }
expandedRowRender={ this.renderExpandedTable }
defaultExpandedRowKeys={ expanded }
expandRowByClick={ true }
showHeader={ false }
dataSource={ tests }
columns={ this.columns }
Expand Down

0 comments on commit cb73bdc

Please sign in to comment.