在角度e2e量角器测试中访问环境变量

时间:2017-03-24 17:47:13

标签: angular protractor angular4

有没有办法将ng应用程序的环境设置连接到量角器e2e对应设备?

   "environmentSource": "environments/environment.ts",
      "environments": {
        "dev": "environments/environment.dev.ts",
        "build": "environments/environment.build.ts",
        "uat": "environments/environment.uat.ts",
        "prod": "environments/environment.prod.ts"
      }

...

import { environment } from '../../../environments/environment';

...

var ev = environment.apiBaseUrl;

我可能会重复自己并进入量角器配置,但是谁喜欢这样做?

0 个答案:

没有答案