配置gitlab以运行Spectron项目中包含的测试以在另一个项目上运行

时间:2019-03-19 13:57:51

标签: continuous-integration gitlab

我有以下用例。在gitlab服务器上,我在

下有一个仓库
gitlabRepoUrl/product/client

该项目是与电子成角的项目。我有一个名为e2e的单独项目,其中包含项目client的e2e测试。回购网址是

gitlabRepoUrl/e2e

在e2e项目的project.json中,我具有以下脚本

"smoke-test": "mocha ./test/specs/smoketests/*.e2e-spec.ts",
"acceptance-test": "mocha ./test/specs/acceptance/*.e2e-spec.ts",
"e2e-test": "mocha ./test/specs/smoketests/*.e2e-spec.ts && mocha ./test/specs/acceptance/*.e2e-spec.ts"

开始不同的测试。

我的问题是如何从客户端项目的.gitlab-ci.yml运行e2e项目的脚本

.gitlab-ci.yaml包含

build-nightly:
  stage: build
  tags:
    - windows
  only:
    refs:
      - master
    variables:
      - $NIGHTLY
  allow_failure: false
  script:
    - call npm install
    - call npm run lint
    - call npm run test-build

0 个答案:

没有答案