在量角器中运行测试用例后,Chrome实例未关闭 [英] Chrome Instances don't close after running Test Case in Protractor

查看:88
本文介绍了在量角器中运行测试用例后,Chrome实例未关闭的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我多次运行测试时,由于PC使用率趋于100%,因此Chrome实例无法关闭.因此,我必须手动结束Chrome实例.可能有某种方法可以解决这个问题?

When I run the test multiple times so Chrome instances do not close due to which PC utilization tends to 100%. So, I have to end Chrome instances manually. There might be some way to handle this?

解决方案:

chromeOptions: {
        args: ["--disable-gpu"]
    },

在配置文件"Disable-gpu"中,只要渲染出现问题(失败),负责禁用chrome加速.

In Configuration file "Disable-gpu" is responsible to disable acceleration of chrome whenever there is some problem in rendering(in-case of failure).

推荐答案

对我们公司中的每个人都有效的另一种解决方案是从如下所示的行中删除配置文件中的"--no-sandbox"自变量

Another solution that has worked for everybody in our company was removing "--no-sandbox" argument from config file from the line that looked like this

chromeOptionsArgs = ["incognito", "--window-size=1920,1080", "disable-extensions", "start-maximized", "--no-sandbox", "--test-type=browser"];

这篇关于在量角器中运行测试用例后,Chrome实例未关闭的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆