testing

Espresso test stuck/inactive after perform(click()) on button in ViewAnimator

前提是你 提交于 2020-01-03 08:25:06
问题 Problem: I'm having an issue while running my Espresso test, after the perform(click()) method is called on the login button, the test keeps running but doesn't go any further until 45 seconds pass and the test automatically fails. Meanwhile, the login happens normally. Context: I have an Activity with two Fragments side by side, the fragment on the right handles the username and password EditTexts and also the login button. This fragment is built with a ViewAnimator and two LinearLayouts as

What is the best mechanism for testing applets?

余生长醉 提交于 2020-01-03 08:06:07
问题 I'm trying to effectively build a functional test suite for an applet, and I'm trying to find a good framework for it. In the past, when I wanted to design a test suite that would serve as both functional and load testing on an application, it has always been a web-based application, or at least some kind of service-based application, and I've used something like grinder to build up test scripts and use them to simulate users. With a Java applet, it's not clear to me what, if any, mechanism

Disable system-level events on Android monkey

扶醉桌前 提交于 2020-01-03 07:23:06
问题 While monkey testing my app % adb shell monkey -p com.foo.bar --throttle 1000 -v 14400 I notice that it accesses various system settings on my device like audio control and taking screen shots. According to http://developer.android.com/tools/help/monkey.html, this is the way it was meant to behave. The Monkey is a program that runs on your emulator or device and generates pseudo-random streams of user events such as clicks, touches, or gestures, as well as a number of system-level events. Is

Option “setupTestFrameworkScriptFile” was replaced by configuration “setupFilesAfterEnv”, which supports multiple paths

↘锁芯ラ 提交于 2020-01-03 07:22:09
问题 Option "setupTestFrameworkScriptFile" was replaced by configuration "setupFilesAfterEnv", which supports multiple paths. Please update your configuration. I found this exact question here: setupTestFrameworkScriptFile is not supported error I renamed my jest.config.js to setUpTests.js however that did not remove the deprecated error warning. import { configure } from 'enzyme' import Adapter from 'enzyme-adapter-react-16' configure({ adapter: new Adapter() }) package.json scripts "scripts": {

Code coverage in sapui5 OPA5 tests

左心房为你撑大大i 提交于 2020-01-03 05:53:07
问题 i can see that in SAPUI5 Qunit tests there is option for checkbox for check the code coverage (by checkbox or with an URL parameter ?coverage) But in OPA5 tests in sapui5 there isn't checkbox for code coverage and if i add the URL parameter ?coverage, the test run regular without code coverage. OPA5 test in sapui5 doesn't support code coverage? Thanks! 回答1: Recently Opa5 introduced component based testing, guessing from 1.34 onwards, the code for calling a component based test looks like

Django user setup for nose tests

那年仲夏 提交于 2020-01-03 05:00:25
问题 I tried seting up a user for nose tests but it doesnot work in global scope defined: from django.contrib.auth.models import User import nose.tools as noz inside a test class defined: def setUp(self): self.client = Client() user = User(username="test", password="test") user.save() The user is saved, which i have tested with the noz.set_trace() but when a test function calls for the same user's login, assertion error is raised: nosetests --verbosity 1 Creating test database for alias 'default'.

How to manage Selenium Project Code using different package (Like page object model/Keyword driver framework)

我只是一个虾纸丫 提交于 2020-01-03 04:34:08
问题 Being first time user for automation I am looking for help related to organization of automation project and other related stuff. Can any one please share sample project with me to star with. I can able write script but I can not able manage code in java. Suggest me any best way any website. 回答1: When starting new web/mobile UI test automation using selenium webdriver, you also need to choose one of the framework that provides common black-box testing needs. Even if you start with available

How to write a Git pre-commit hook that prevents committing of an Android project if the test project fails?

旧巷老猫 提交于 2020-01-03 03:07:30
问题 Given that I in my workspace I have an android project MyAndroidProject and my tests project MyAndroidProjectTests directories how could I write a pre-commit git hook that will run the tests in the MyAndroidProjectTests and refuse to commit any code changes if the tests fail? When I run tests on the terminal they usually have output like this: com.mydomain.tests.Models.MyProjectTests:....... Test results for InstrumentationTestRunner=....... Time: 0.05 OK (10 tests) What I'm unsure about is

How to host VS IDE during integration test via MSTest?

一个人想着一个人 提交于 2020-01-03 02:56:38
问题 I have created an integration test project to test VS Extension. If I run the tests from the Visual Studio IDE, all tests are running just fine and every method spawns a new VS IDE. The test methods are marked with the following attributes: [HostType("VS IDE")] [TestMethod] public void TestWhateverMethod() { ... } However if I try to automate the tests, and run them from commandline via MSTest (or VSTest) I got the following error message, for the tests that are hosted inside the VS IDE: The

Calabash Android: Is there a special perform_action command for pressing the search button on the Android keyboard

筅森魡賤 提交于 2020-01-03 02:31:09
问题 The command perform_action('send_key_enter') sends the enter key but for our search field, the enter key is replaced by the search key in the Android keyboard. Is there a special perform_action command to send the input of the search key? 回答1: What could be happening is your scripts aren't able to accurately locate ADB in order to send the command to the device. Try using the following, which uses default_device.adb_command - this should use the full path to ADB and also use the proper device