wdi5 icon indicating copy to clipboard operation
wdi5 copied to clipboard

Running wdi5 tests in SAP Business Application Studio (BAS) using chromium 87.0.4280.141

Open gregorwolf opened this issue 2 years ago β€’ 11 comments

Describe the bug

I try to get wdi5 tests working in SAP BAS. I would hope that this is possible as at least chromium ist installed. This can be checked by running

$ chromium --version
Chromium 87.0.4280.141 built on Debian 10.7, running on Debian 10.8

The path to chromium is:

$ which chromium
/extbin/bin/chromium

When running:

> chromium --headless --screenshot https://bestofui5.org

I can also produce a screenshot:

screenshot

so I think chromium is fully functional.

To Reproduce

  1. Clone the https://github.com/ui5-community/wdi5-workshop repository
  2. run npm i
  3. cd fe-app
  4. adjust fe-app/wdio.conf.js
         browserName: "chromium",
         binary: "/extbin/bin/chromium",
  1. run npm run wdi5and you will see the following error
> [email protected] wdi5
> run-p -r serve _wdi5


> [email protected] serve
> ui5 serve --port 8088


> [email protected] _wdi5
> wait-on tcp:8088 && wdio run wdio.conf.js

info normalizer:translators:ui5Framework Using SAPUI5 version: 1.97.2
WARN normalizer:projectPreprocessor Dependency sap.fe.test is restricted for use by SAP internal projects only! If the project incidents is an SAP internal project, add the attribute "allowSapInternal: true" to its metadata configuration
WARN normalizer:projectPreprocessor Dependency sap.fe.templates is restricted for use by SAP internal projects only! If the project incidents is an SAP internal project, add the attribute "allowSapInternal: true" to its metadata configuration
info server:ux-fe-mockserver JSON file found for Category
info server:ux-fe-mockserver JSON file found for IncidentStatus
info server:ux-fe-mockserver JSON file found for IncidentFlow
info server:ux-fe-mockserver JSON file found for IncidentProcessTimeline
info server:ux-fe-mockserver JSON file found for Incidents
Server started
URL: http://localhost:8088
info server:ux-fe-mockserver JSON file found for Individual
info server:ux-fe-mockserver JSON file found for Priority

Execution of 1 workers started at 2022-08-10T22:03:16.950Z

SevereServiceError in "onPrepare"
SevereServiceError: 
A service failed in the 'onPrepare' hook
SevereServiceError: Couldn't start Chromedriver: timeout
Chromedriver failed to start.
    at ChromeDriverLauncher.onPrepare (/home/user/projects/wdi5-workshop/node_modules/wdio-chromedriver-service/build/launcher.js:106:13)
    at async /home/user/projects/wdi5-workshop/node_modules/@wdio/cli/build/utils.js:35:17
    at async Promise.all (index 0)
    at async Launcher.run (/home/user/projects/wdi5-workshop/node_modules/@wdio/cli/build/launcher.js:86:13)



Stopping runner...
    at /home/user/projects/wdi5-workshop/node_modules/@wdio/cli/build/utils.js:51:35
    at async Launcher.run (/home/user/projects/wdi5-workshop/node_modules/@wdio/cli/build/launcher.js:86:13)
HookError [SevereServiceError]: 
A service failed in the 'onPrepare' hook
SevereServiceError: Couldn't start Chromedriver: timeout
Chromedriver failed to start.
    at ChromeDriverLauncher.onPrepare (/home/user/projects/wdi5-workshop/node_modules/wdio-chromedriver-service/build/launcher.js:106:13)
    at async /home/user/projects/wdi5-workshop/node_modules/@wdio/cli/build/utils.js:35:17
    at async Promise.all (index 0)
    at async Launcher.run (/home/user/projects/wdi5-workshop/node_modules/@wdio/cli/build/launcher.js:86:13)



Stopping runner...
    at /home/user/projects/wdi5-workshop/node_modules/@wdio/cli/build/utils.js:51:35
    at async Launcher.run (/home/user/projects/wdi5-workshop/node_modules/@wdio/cli/build/launcher.js:86:13) {
  origin: 'onPrepare'
}
npm ERR! Lifecycle script `_wdi5` failed with error: 
npm ERR! Error: command failed 
npm ERR!   in workspace: [email protected] 
npm ERR!   at location: /home/user/projects/wdi5-workshop/fe-app 
ERROR: "_wdi5" exited with 1.
npm ERR! Lifecycle script `wdi5` failed with error: 
npm ERR! Error: command failed 
npm ERR!   in workspace: [email protected] 
npm ERR!   at location: /home/user/projects/wdi5-workshop/fe-app 

Expected behavior

Running wdi5 tests in SAP Business Application Studio (BAS) should be possible.

gregorwolf avatar Aug 10 '22 22:08 gregorwolf

Hi Gregor,

thanks for providing such detailed information and context! We are already aware of this problem and are exchanging information with BAS colleagues. As I understand it, this is not a wdi5 problem for the time being. Apparently, certain dependencies that we need are missing in the Docker images on which we work in BAS.

The colleagues are already looking at this. Unfortunately I can't tell you when it will be possible to start wdi5 tests in BAS.

Regards, Simon

Siolto avatar Aug 15 '22 07:08 Siolto

Hi @Siolto ,

thank you for the follow up. Would it help if I create an customer incident? As BAS is SAP's promoted development infrastructure and wdi5 is the standard integration test tool for SAPUI5 apps now I think it should work out of the box in BAS.

Best Regards Gregor

gregorwolf avatar Aug 16 '22 10:08 gregorwolf

@gregorwolf definitely! I think when they also get the feedback from customers and partners that there is a major piece missing in their tooling, this could get more attention and resolved faster.

btw: UIVeri5 hast never worked either in BAS when I remember it correctly more or less for the same reasons.

Regards, Simon

Siolto avatar Aug 16 '22 10:08 Siolto

I've created SAP Support Incident 601180 / 2022

gregorwolf avatar Aug 16 '22 13:08 gregorwolf

The Incident was answered with:

The WDI5 is not supported in BAS currently. As it is not an error but a feature request, please initiate it on SAP Influence site https://influence.sap.com/

I did that and created the request: Support the execution of wdi5 tests (S-User required). Please vote for this request.

gregorwolf avatar Aug 18 '22 13:08 gregorwolf

hey πŸ‘‹ - silence for 30 days 🀐 ... anybody? πŸ˜€

github-actions[bot] avatar Sep 18 '22 04:09 github-actions[bot]

9 Votes for the request. But Status still only Submitted.

gregorwolf avatar Sep 18 '22 09:09 gregorwolf

hey πŸ‘‹ - silence for 30 days 🀐 ... anybody? πŸ˜€

github-actions[bot] avatar Oct 20 '22 03:10 github-actions[bot]

the influence request is still open. yet it is only in status "submitted" :( probably @nicoschoenteich can reach out and check w/ Oliver Graeff what the plans are going forward for BAS + wdi5?

vobu avatar Oct 20 '22 07:10 vobu

Hi all, I reached out to Oliver πŸ‘

nicoschoenteich avatar Oct 20 '22 15:10 nicoschoenteich

Hi all, This is being reviewed internally currently. Hope to have a road map item ready very soon.

nicoschoenteich avatar Oct 24 '22 07:10 nicoschoenteich

hey πŸ‘‹ - silence for 30 days 🀐 ... anybody? πŸ˜€

github-actions[bot] avatar Nov 24 '22 02:11 github-actions[bot]

14 Votes now for the influencing request.

gregorwolf avatar Nov 24 '22 07:11 gregorwolf

hey πŸ‘‹ - silence for 30 days 🀐 ... anybody? πŸ˜€

github-actions[bot] avatar Dec 26 '22 02:12 github-actions[bot]

I've tested again with the new VS Code based BAS. Unfortunately it's still the same problem:

user: fe-app $ npm run wdi5

> [email protected] wdi5
> wdio run wdio.conf.js

Execution of 1 workers started at 2023-01-06T20:33:51.746Z

SevereServiceError in "onPrepare"
SevereServiceError: 
A service failed in the 'onPrepare' hook
SevereServiceError: Couldn't start Chromedriver: timeout
Chromedriver failed to start.
    at ChromeDriverLauncher.onPrepare (/home/user/projects/wdi5-workshop/ui5con2022/node_modules/wdio-chromedriver-service/build/launcher.js:106:13)
    at async /home/user/projects/wdi5-workshop/ui5con2022/node_modules/@wdio/cli/build/utils.js:35:17
    at async Promise.all (index 0)
    at async Launcher.run (/home/user/projects/wdi5-workshop/ui5con2022/node_modules/@wdio/cli/build/launcher.js:86:13)

Stopping runner...
    at /home/user/projects/wdi5-workshop/ui5con2022/node_modules/@wdio/cli/build/utils.js:51:35
    at async Launcher.run (/home/user/projects/wdi5-workshop/ui5con2022/node_modules/@wdio/cli/build/launcher.js:86:13)
HookError [SevereServiceError]: 
A service failed in the 'onPrepare' hook
SevereServiceError: Couldn't start Chromedriver: timeout
Chromedriver failed to start.
    at ChromeDriverLauncher.onPrepare (/home/user/projects/wdi5-workshop/ui5con2022/node_modules/wdio-chromedriver-service/build/launcher.js:106:13)
    at async /home/user/projects/wdi5-workshop/ui5con2022/node_modules/@wdio/cli/build/utils.js:35:17
    at async Promise.all (index 0)
    at async Launcher.run (/home/user/projects/wdi5-workshop/ui5con2022/node_modules/@wdio/cli/build/launcher.js:86:13)

Stopping runner...
    at /home/user/projects/wdi5-workshop/ui5con2022/node_modules/@wdio/cli/build/utils.js:51:35
    at async Launcher.run (/home/user/projects/wdi5-workshop/ui5con2022/node_modules/@wdio/cli/build/launcher.js:86:13) {
  origin: 'onPrepare'
}
npm ERR! Lifecycle script `wdi5` failed with error: 
npm ERR! Error: command failed 
npm ERR!   in workspace: [email protected] 
npm ERR!   at location: /home/user/projects/wdi5-workshop/ui5con2022/fe-app 

gregorwolf avatar Jan 06 '23 20:01 gregorwolf

Hello Team,

Can you please provide the step to step document for simple sap ui5 application testing vs. code for wdi5.

I have tried a lot of things but the issue is not resolved.

Thanks, Pragnesh

pragu4 avatar Jan 12 '23 00:01 pragu4

@pragu4 does your question relate to this issue? Or do you have issues getting wdi5 to work in your local VS Code?

gregorwolf avatar Jan 12 '23 06:01 gregorwolf

hey πŸ‘‹ - silence for 30 days 🀐 ... anybody? πŸ˜€

github-actions[bot] avatar Feb 12 '23 02:02 github-actions[bot]

23 Votes now for the influencing request.

gregorwolf avatar Feb 12 '23 08:02 gregorwolf

The influence request is now officially Accepted and included in the development planning: https://influence.sap.com/sap/ino/#/idea/287947/?section=sectionDetails

nicoschoenteich avatar Mar 01 '23 15:03 nicoschoenteich

hey πŸ‘‹ - silence for 30 days 🀐 ... anybody? πŸ˜€

github-actions[bot] avatar Apr 01 '23 02:04 github-actions[bot]

this is about to be released, me heared...albeit with a limited scope, but still! πŸ‘

vobu avatar Apr 01 '23 06:04 vobu

hey πŸ‘‹ - silence for 30 days 🀐 ... anybody? πŸ˜€

github-actions[bot] avatar May 02 '23 02:05 github-actions[bot]

about to come with #459 :)

vobu avatar May 02 '23 08:05 vobu

multiple beta testers (thanks @marianfoo and @nicoschoenteich!) reported that the current BAS extension enabling wdi5 in BAS doesn't work - see https://twitter.com/mianbsp/status/1653848495839760384?s=20 and https://twitter.com/NicoSchoenteich/status/1654041518817116162?s=20

vobu avatar May 04 '23 11:05 vobu

Hi, Regarding https://twitter.com/NicoSchoenteich/status/1654041518817116162?s=20 problem, he just needs to create a 'profile' folder. Just write Χ΄mkdir /tmp/profileΧ΄ in the terminal and it should run.

Regarding https://twitter.com/mianbsp/status/1653848495839760384?s=20, it seems the configuration is incorrect, if it is possible to add the configuration file, I would be happy to take a look and try to help.

NetaMolcho avatar May 04 '23 14:05 NetaMolcho

Here is my Config https://github.com/marianfoo/ui5-cc-excelUpload/commit/492bf5785183a65a7859f7a80e4bbeeb042476ef

marianfoo avatar May 04 '23 14:05 marianfoo

Hi @marianfoo I see your baseUrl is 'http://localhost:8080/index.html', but in the package.json I don't see "ui5 serve --port 8080". are you sure that there is a running UI5 app? If you want, we can schedule a meeting for next week (because in Israel the weekend is already started) so we will do the scenario together and try to solve it.

NetaMolcho avatar May 04 '23 15:05 NetaMolcho

Hi @NetaMolcho , the setup is now working for me. I had to downgrade geckodriver to 3.1.0. But I still had to install these two npm packages in addition to the changes in the wdio config:

See here my changes from chrome to firefox for BAS https://github.com/marianfoo/ui5-cc-excelUpload/pull/180/files

Here is the working wdio run: image

marianfoo avatar May 05 '23 11:05 marianfoo

Great, thank you for the update (:

NetaMolcho avatar May 07 '23 07:05 NetaMolcho