I'm looking for a way to easily test any flow. And I thing that spring-cloud-dataflow-acceptance-tests could help me to do that but I can'f find any documentation about that.
How does it work? I launched the application but I don't know how can write and run test.
Does anyone has any suggestion about that?
Thanks
The spring-cloud-dataflow-acceptance-tests is used to deploy and run test scenarios. The readme has an extensive example on how to bootstrap it, is your question about how to write a test for a stream app, or how to test a deployed stream end to end?
Related
This question already has answers here:
Deploying microservice to be tested within the test [duplicate]
(3 answers)
Closed 1 year ago.
Let me give some background. We're trying to do e2e testing between a bunch of spring boot services that write to kafka, move files and talk to other services to do the file moving. I think we're pretty good on integration testing with mocks and whatnot, but is there a way to leverage karate or any other testing framework to help achieve fully e2e for the few major scenarios? Like can i have a test on one service that takes actual data and sends to the next service without mocking?
I hope that made sense. Thank you.
It really does not matter whether the "system under test" is a single service or a collection of services - we just need to think in terms of input to the system, and the outputs from the system. From the description it looks like, the "system under test" does ...
(a) interact with some downstream services : you should be able to mock them using Karate
(b) produces to Kafka : See if https://github.com/Sdaas/karate-kafka can help here
(c) does some file i/o
For the last one, you may need to write some custom Java code that can be called from within Karate. See https://github.com/Sdaas/karate-kafka/tree/master/src/test/java/karate/java for some examples.
As you said, karate is for e2e testing. The answer is quite easy: if you can assess changes in your overall state across all microservices according to the result of some action(s), then yes.
Of course all these changes, actions and assessments have to be HTTP, since it is Karate’s main protocol.
The answer is yes. Even within the same Scenario you can make calls to 2 different URL-s. So for example you can GET from service A and use the response to POST to service B.
i'm working on a GitLab CI implementation of ZAP.
What i'm trying to archive, is to perform tests directly in the project, and check the results in the pipeline. I need your help to understand how i can write a yml file to test all the urls present in the application to test.
Is there anyone who already did this?
Thx
GitLab Team member here. I definitely don't pretend to be an expert on ZAP and how to integrate it, however, this StackOverflow thread seems like a promising example of executing successfully using something like Docker.
Let me know if this reply misses the mark, but I hope it at least gets you one step closer.
I need to do FIX-API based performance testing.
Can you please let me know few way ahead.
Also if I need to develop the in-house plugin then please can you point in some direction that how to do that?
Also does any 3rd party tool like loadrunner or neoload directly support FIX-API protocol testing?
Thanks
This has been asked many times before in many different forums. Please leverage Google for keywords of LoadRunner and FIX for FIXML as aprpopriate
If you want to do a test in FIX protocol over a FIX connection you can try using the FIXRobot. FIXRobot allows to easily write the tests in python. You can include a loop in the test script to pump messages and calculate the perf statistics from your application logs writing some scripts.
I am writing an open source gem that interacts with an sms service. I want to test the interaction, however it needs account information and a phone number to run. It also needs feedback to determine if sms messages were being sent correctly. This causes two problems:
I can't put the account information in the test file, as the gem is open source and anyone could get to it.
I need the person running the test to give information to the script as it is running (eg checking the phone to see if a message was received).
What techniques or libraries are available that can help with this? I'm currently using rspec and making it prompt for parameters (using gets), however it is pretty cluncky at the moment. I can't be the first person using ruby to have this problem, and I feel that I'm missing a gem or something that solves this problem.
Use mocks
What are your tests testing, specifically? That a given login/password works? Probably not. Most likely you want to make sure your code reacts to the API properly. Therefore, I'd suggest mocking. Save the output of the API calls and use a mock service to return those responses. Then test. Your tests will be faster and less brittle as a happy side-effect.
More information on mocking with RSpec is here:
http://rspec.info/documentation/mocks/
Re 1) Why not just save configuration options in a YAML file and load them at the beginning of your tests?
Re 2) Are there maybe any web services for that? E.g. one where you can send a message to and query an API to see if it worked. I know this can be unreliable, but the same is true for a user's phone company network.
+1 for Mark Thomas' answer on mocking. Two more alternative mock object libraries for Ruby: FlexMock and Mocha
I'm still new to PHPUnit Testing and seleniumRC, but i have managed to get them both working, so now i was wondering if it is possible to sent out an email when the test fails and passes after every test is run. the mail should go to the developer and the testing manager. is it possible to do that? and it would be very nice to generate a whole report and sent it out on all the test results. can someone please give me a proper direction which i can follow on how to get around this.
Thank you in advance
D~~
You have a few options available. For a small project, maybe a plain php script that redirects phpunit output to a file, parses it and acts accordingly. ob_start() could also be your friend for this task.
Getting into more complicated options, you could look also into using a couple of phing tasks for this. Then, last but not least, the holy-grail: very flexible for most any build tasks and best of all automated -> look into continuous integration tools such as the jenkins.
For small one-man team projects I opt for the simplest.