日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

SAP Spartacus cypress集成测试执行失败的一些常见原因

發布時間:2023/12/19 编程问答 41 豆豆
生活随笔 收集整理的這篇文章主要介紹了 SAP Spartacus cypress集成测试执行失败的一些常见原因 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

SAP Spartacus 端到端的集成測試代碼實現,位于下列文件夾內:

錯誤消息:

CypressError: cy.route cannot be invoked before starting the cy.server()

測試覆蓋率:

先執行Spartacus B2B模塊budget的集成測試:

再執行cost center:

這些集成測試的實現代碼,位于integration/b2b/regression/my-company下面:

再執行purchase limit:

第一次build失敗,我在Travis的控制臺上點了Restart job,第二次就成功了:

Coverage summary:測試覆蓋率一覽。

這個build貌似還有超時的時間限制,若10分鐘內沒收到任何output,build就終止了。

No output has been received in the last 10m0s, this potentially indicates a stalled build or something wrong with the build itself.
1364Check the details on how to adjust your build configuration on: https://docs.travis-ci.com/user/common-build-problems/#build-times-out-because-no-output-was-received
1365
1366The build has been terminated

成功消息:

Success: Spartacus production build was successful.

Running Cypress end to end tests 1011yarn run v1.22.5 1012$ start-server-and-test start:ci:b2b http-get://localhost:4200 e2e:cy:run:ci:2005:b2b 10131: starting server using command "npm run start:ci:b2b" 1014and when url "[ 'http-get://localhost:4200' ]" is responding with HTTP status code 200 1015running tests using command "npm run e2e:cy:run:ci:2005:b2b" 1016 1017npm WARN lifecycle The node binary used for scripts is /tmp/yarn--1612152243389-0.11358567514273044/node but npm is using /home/travis/.nvm/versions/node/v12.16.1/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with. 1018 1019> storefrontapp@3.0.0 start:ci:b2b /home/travis/build/SAP/spartacus 1020> cross-env SPARTACUS_BASE_URL=https://spartacus-devci767.eastus.cloudapp.azure.com:9002 SPARTACUS_API_PREFIX=/occ/v2/ SPARTACUS_B2B=true yarn start 1021 1022$ ng serve 1023env= { 1024 SPARTACUS_API_PREFIX: '"/occ/v2/"', 1025 SPARTACUS_BASE_URL: '"https://spartacus-devci767.eastus.cloudapp.azure.com:9002"', 1026 SPARTACUS_B2B: '"true"' 1027}

下圖可以看到ng serve 命令行啟動時,如何通過環境變量的方式注入參數到啟動命令行:

開始運行集成測試:

The command ./build.sh sonar exited with 0

這只是Travis build其中之一。

更多Jerry的原創文章,盡在:“汪子熙”:

創作挑戰賽新人創作獎勵來咯,堅持創作打卡瓜分現金大獎

總結

以上是生活随笔為你收集整理的SAP Spartacus cypress集成测试执行失败的一些常见原因的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。