integration-testing

How to mock Amazon S3 in an integration test

做~自己de王妃 提交于 2019-12-04 22:42:54
I'm trying to get an "walking skeleton" of my app up that will use S3 for persistence. I would like to use a fake S3 service so each developer's desktop can read/write at will. I thought mocks3 would be perfect, as I could get a jetty server up in my jUnit tests. The problem is that mocks3 doesn't allow any writes . Not even to set it up as far as I can tell. So how do others do this? Tornado, a python web framework, has an example app that is just what you're looking for. https://github.com/facebook/tornado/blob/master/demos/s3server/s3server.py It can be used out of the box. There is also an

Integration test for image download java

坚强是说给别人听的谎言 提交于 2019-12-04 20:50:17
I'm trying to write an integration test to see if a file is downloaded correctly from a url. I'm not sure how to test this because I expect to get the file in byte[] but I not really sure about the image that I'm comparing it to. I thought about downloading the file manually and then convert it to bytes and take the result and paste it in the code as the expected value and than compare it to the result i get. If you have a better idea I would be glad to hear it. Thanks:) Comparing the images' hash value will be helpful. Compute the hash value before and after downloading the file. Compare the

KIF output: AX Exchange error: Error Domain=Accessibility Code=0 “Remote service does not respond to _accessibilityMachPort”

拈花ヽ惹草 提交于 2019-12-04 20:28:16
问题 When running KIF integration tests on device with iOS 8.1.3 I get lots of diagnostic messages of the following kind as console output: AX Exchange error: Error Domain=Accessibility Code=0 "Remote service does not respond to _accessibilityMachPort" UserInfo=0x1a55de50 {NSLocalizedDescription=Remote service does not respond to _accessibilityMachPort} This occurs during a call to waitForAccessibilityElement:view:withElementMatchingPredicate:tappable: . Otherwise testing works as expected, it

Is unit testing needed in addition to integration testing of DB, filesystem, etc.?

馋奶兔 提交于 2019-12-04 20:00:38
At my office we have a dispute regarding the necessity of unit tests in addition to integration tests for the classes that have the main responsibility of interacting with a filesystem (DB, etc). The integration tests we have, are almost unit tests, as the tested object doesn't interact with other objects at all. The only reason, why we call the tests integration , is that the real filesystem is used in tests. And it is proposed to make the tested class use filesystem layer component, then mock it in tests (so we will call them unit tests), and check interaction with this component, rather

How can I specify the path to JUnit results from integration tests?

為{幸葍}努か 提交于 2019-12-04 19:56:21
So I know there is sonar.junit.reportsPath that is read by the Java plugin and takes a single directory of XML files to parse. But what if I do not have one directory of test results, but two, specifically one for unit tests and one for integration tests? The more recent versions of Sonarqube gained some support for reporting coverage of these different test results via sonar.jacoco.reportPath and sonar.jacoco.itReportPath . I also find some references on the internet about sonar.junit.itReportsPath , but not in the official documentation or sources, so I guess its unsupported. TL;DR - where

Running docker-container tests on circleCI

假如想象 提交于 2019-12-04 19:35:31
I have created some integration tests for my open-sourced code and I am looking for a publicly accessible CI service to host them. As Travis-CI has to small quotas for all my containers, I think I will use CircleCI. This is my cirle.yml : machine: services: - docker dependencies: override: - pip install docker-compose test: override: - cd integration-tests && docker-compose run --rm runner However after running this I get error message "client and server don't have same version (client : 1.18, server: 1.16)" What is my problem? @zefciu This config just worked for me machine: services: - docker

Integration testing with White [closed]

别来无恙 提交于 2019-12-04 19:09:38
问题 It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 6 years ago . Has anyone got experience with the white framework? www.codeplex.com/white ? I'm thinking about using it for the next project for basic smoke tests of our windows client. I'd like some advice on articles or your

Writing integration tests against external resources which are A/B testing

雨燕双飞 提交于 2019-12-04 18:34:25
I have a bit of a design question and I'm curious if other users have run into this and how to develop the most elegant solution. I have some integration type feature tests in Cucumber using Capybara/Celerity/Selenium. A portion of these tests drive an external website to see how well my resources integrate (cookies, Javascript, etcetera). One particular external site is undergoing their own heavy A/B testing with a similar but significantly different site design, so my tests fail with the new and work with the old, and thus only pass about 50% of the time. Obviously re-writing my tests for

Integration test per layer is a good practice?

北慕城南 提交于 2019-12-04 18:17:42
问题 I have an application that use spring-mvc, basically we have a presentation layer (controllers), service layer (business units, helpers), integration layer and data access layer(jdbc/jpa repositories), we want to ensure using testing that future addition to the code won't break nothing that was previously working, to do this we are using unit testing(mockito) and integration testing (spring-test,spring-test-mvc). Unit testing is made per class/component, basically we tried to have a good

Separating integration tests from unit tests in Android Studio

岁酱吖の 提交于 2019-12-04 18:06:43
问题 I'm trying to separate out integration tests in Android Studio 0.9. I have added the following to the build file: sourceSets { integrationTest { java.srcDir file('src/integrationTest/java') } } task integrationTest(type: Test) { testClassesDir = sourceSets.integrationTest.output.classesDir classpath = sourceSets.integrationTest.runtimeClasspath } I've run into a couple of issues: The task will run but it doesn't have the rest of the project files available so I get errors about missing