@@ -31,6 +31,7 @@ import { ITestWorkspaceUtil } from '../../utils/workspace/ITestWorkspaceUtil';
3131import { Dashboard } from '../../pageobjects/dashboard/Dashboard' ;
3232import { CreateWorkspace } from '../../pageobjects/dashboard/CreateWorkspace' ;
3333import { ViewsMoreActionsButton } from '../../pageobjects/ide/ViewsMoreActionsButton' ;
34+ import { SourceControlView } from '../../pageobjects/ide/SourceControlView' ;
3435
3536suite (
3637 `Create a workspace via launching a factory from the ${ FACTORY_TEST_CONSTANTS . TS_SELENIUM_FACTORY_GIT_PROVIDER } repository ${ BASE_TEST_CONSTANTS . TEST_ENVIRONMENT } ` ,
4748 const dashboard : Dashboard = e2eContainer . get ( CLASSES . Dashboard ) ;
4849 const createWorkspace : CreateWorkspace = e2eContainer . get ( CLASSES . CreateWorkspace ) ;
4950 const viewsMoreActionsButton : ViewsMoreActionsButton = e2eContainer . get ( CLASSES . ViewsMoreActionsButton ) ;
51+ const sourceControlView : SourceControlView = e2eContainer . get ( CLASSES . SourceControlView ) ;
5052
5153 let projectSection : ViewSection ;
5254 let scmProvider : SingleScmProvider ;
@@ -103,8 +105,10 @@ suite(
103105 } ) ;
104106
105107 test ( 'Check if the project files were imported' , async function ( ) : Promise < void > {
106- const label : string = BASE_TEST_CONSTANTS . TS_SELENIUM_PROJECT_ROOT_FILE_NAME ;
107- expect ( await projectAndFileTests . getProjectTreeItem ( projectSection , label ) , 'Project files were not imported' ) . not . undefined ;
108+ expect (
109+ await projectAndFileTests . getProjectTreeItem ( projectSection , BASE_TEST_CONSTANTS . TS_SELENIUM_PROJECT_ROOT_FILE_NAME ) ,
110+ 'Project files were not imported'
111+ ) . not . undefined ;
108112 } ) ;
109113
110114 test ( 'Make changes to the file' , async function ( ) : Promise < void > {
@@ -166,10 +170,7 @@ suite(
166170 . getDriver ( )
167171 . findElement ( ( webCheCodeLocators . ScmView as any ) . scmEditor )
168172 . click ( ) ;
169- Logger . debug ( `Type commit text: "Commit ${ changesToCommit } "` ) ;
170- await driverHelper . getDriver ( ) . actions ( ) . sendKeys ( changesToCommit ) . perform ( ) ;
171- Logger . debug ( 'Press Enter to commit the changes' ) ;
172- await driverHelper . getDriver ( ) . actions ( ) . keyDown ( Key . CONTROL ) . sendKeys ( Key . ENTER ) . keyUp ( Key . CONTROL ) . perform ( ) ;
173+ await sourceControlView . typeCommitMessage ( changesToCommit ) ;
173174 await driverHelper . waitVisibility ( webCheCodeLocators . ScmView . more ) ;
174175 await driverHelper . wait ( timeToRefresh ) ;
175176 Logger . debug ( `wait and click on: "${ refreshButtonLabel } "` ) ;
0 commit comments