我有一个需要进入Google身份验证的网页,然后才能进入一个有角度的网页,并且我已经建立了一些非常基本的端到端测试,这些测试在Linux中与Chrome Headless一样具有吸引力:
这是我在终端机中收到的最后一条消息:在46秒内成功执行3项规格中的3项。
但是,在AWS CodeBuild中,我们也使用Linux(Ubuntu)容器,并且一次失败[[every。这是第一个错误:...茉莉花开始
capabilities: {
'browserName': 'chrome',
chromeOptions: {
args: ["--headless", "--disable-dev-shm-usage", "--no-sandbox", "--disable-gpu", "--window-size=1280x960"]
}
},
directConnect: true, // Test scripts communicate directly with Chrome Driver, so they start up and run faster
从package.json,我正在使用:“ e2e”:“ ng e2e --port 4200”,从buildspec-test.yml,我有以下post_build命令:-npm运行e2e
为什么Chrome Headless在http://localhost:4200上找不到我的网页,而在本地Linux发行版上却没有问题,但是当他们都运行Ubuntu Linux时却无法在AWS CodeBuild中找到它?本地版本:Ubuntu 18.04.1 LTSAWS CodeBuild版本:Ubuntu Ubuntu 14.04.5 LTS(Trusty)
请让我知道,并提前致谢!
真诚地,
PW