qaf | Quality Automation Framework for web , mobileweb , mobile | Functional Testing library
kandi X-RAY | qaf Summary
kandi X-RAY | qaf Summary
for web, mobileweb, mobile native and rest web-service functional test automation. Online documentation | Step-By-Step-Tutorial.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Post the test set
- Send email
- Create an image part
- Converts milliseconds to milliseconds
- Parse a feature file
- Returns the type of a line
- Gets meta data
- Sets the examples
- Reads csv file
- Renames a file
- Entry point for testing
- Invoke a method on an array of Objects
- Updates the report
- Execute a command and execute it
- Move a node
- Initializes the meta data
- Creates the WSC file
- Do the average match of two images
- Fill random data
- Parse the feature file
- Parse the BDD file
- Get Excel data as Map
- Determines if the specified reference file contains a template reference
- Scan text file
- Do the actual execution
- Get the dataset data as a Map
qaf Key Features
qaf Examples and Code Snippets
Community Discussions
Trending Discussions on qaf
QUESTION
I am using QAF framework BDD2 for regression automation. I know how to setup setup() and teardown() webdriver in testNG but I am not sure do we have capability to set up the same QAF BDD2 setup() and teardown(). Kindly help with some examples.
I will provide a usecase which helps to understand exactly I am looking for:
- whenever I wanted to run the test suite, I want to create a custom downloads folder in c:/users/XXX. Where this folder contains all my test downloads.
- At setup() I want to implement createCustomFolder() method to create the custom folder before the test suite begins
- At the end of all tests in test suite. I want to implement teardown() methods where it contains delete files() deletes the files inside the custom folder and delete custom folder() delete the folder.
ANSWER
Answered 2022-Feb-15 at 08:44You can take benefit of testng listener and qaf listeners. For example, in above use case, implement testng suite listener and do the needful in before and after suite methods:
QUESTION
Error
Meta-data: {"dataFile":"resources/env1/data.json","description":"Data driven test that uses enter code herejson file to provide data"}@scenarios/jsonformfiller.feature#5 TestStep implementation not found. Please provide implementation or ensure 'step.provider.pkg' property value includes appropriate package.
Step Definition
...ANSWER
Answered 2022-Feb-04 at 19:20Gherkin syntax doesn't have support of meta-data. You can use BDD2 syntax which is superset of Gherkin. In BDD2 you can provide scenario metadata on top of scenario:
Feature File
QUESTION
I tried installing denon
for running my deno script
I used the following command from their docs,
...ANSWER
Answered 2022-Feb-06 at 20:50Edit: This issue has been fixed in denon v2.5.0
Original answer:
This is a known bug in denon
, an official fix will be released soon but in the meantime there is a patch which you can install to workaround the issue, see this comment on GitHub:
QUESTION
I am getting the following error while runing testng config for QAFTestSteps:
Error shown
...ANSWER
Answered 2022-Feb-03 at 17:53Looks like version compatibility issue. Use latest version of qaf 3.1.0-RC2
with testng 7.4.0
.
Updating version will fix above error, still you will see issue related to step. The reason is following steps:
QUESTION
I'm using switchDriver('appiumRemoteDriver') & switchDriver('chromeRemoteDriver') to connect between Web and mobile within the same scenario.
I'm not able to use switchDriver("appiumDriver") / switchDriver("iosDriver") / switchDriver("androidDriver") to connect with ExperiTest or pCloudy.
One of the issues I'm facing by using appiumRemoteDriver is that I'm not able to use QAF's mobile-support pack with common steps or are not able to execute custom commands. Eg:
...ANSWER
Answered 2022-Feb-01 at 19:58Remove remote
from driver.name
. Instead of using value appiumRemoteDriver
use appiumDriver
and set driverClass
capability.
To use device from cloud set url provided by cloud service provider as value of remote.server
.
For example:
QUESTION
Does QAF support the Dependent Scenario option out of the box? I have read in the below link that dependsOnMethods is not working and not supported.
https://github.com/qmetry/qaf/issues/281
If the dependent scenario option is not available in QAF out of the box, can we write a custom function to check the dependent scenario result and Skip the executing scenario if the dependent scenario has failed? Any past posts or guidance will be very helpful.
Note: I'm using BDDTestFactory2.
###################### UPDATED ######################
Tried below code in testng listner, but it is not skipping the test.
...ANSWER
Answered 2022-Jan-29 at 00:53Test dependency is supported for test/scenario written in java with QAF.
Having dependency between scenarios in BDD is not a good idea, one of the possible way is, set flag in after method and check flag in before method using testng listener. Let say scenario-2 is dependent on scenario-1,
- make sure the order in you feature file is correct
- in after method check if test name or metadata is scenario-1 and status is fail, set flag let say
my-precondition
tofalse
. - in before method check if test name or metadata is scenario-2 and
my-precondition
isfalse
, throwSkipExeption
.
Above approach may have possible side-effects as well.
If you want to take benefit of test dependency along with BDD, it is supported with RuntimeScenarioFactory
. The good part of it is, it doesn't required separate feature file. If you required to have feature file for any reason you can generate feature files using Behavior Generator. Furthermore, with RuntimeScenarioFactory
you can have more programing control then scenario in feature file.
You also can have combination of tests in feature file (scenarios) as well as test in java file(using RuntimeScenarioFactory). Both has same capabilities for example: detailed reporting, dry run, data-driven, meta-data, meta-data filter etc.
EDIT: Below example worked fine for me.
Example feature file:
QUESTION
Facing some weird issue when using QAF common steps. We just facing in “I click” and “I clear” methods so far.
Step to reproduce: Step: And I click on "LOGIN_btn||rt.loc.e8R5BmyEUI"
...ANSWER
Answered 2022-Jan-20 at 09:36Check all entries of step.provider.pkg
. Most probably the reason is you have another library specifying step with same name with same description and step loaded from it.
For example if you are using Perfecto-Quantum it has step with same name and description. The simplest way to find out is editor content-assist in IDE. You will see all available step definitions in content assist.
QUESTION
Im currently using QAF at my job and recently setup a few CICD tests using Azure Devops.
Azure Devops at the moment is only designed to read to Junit .XML
results in their reporting dasbboard.
When running a Maven test, TestNG automatically creates a JunitReports folder that has a .xml report in it.
The issue is that when using QAF and using BDDStepFactory2
in my config.xml
file, my junit report shows all tests as ignored.
Is there a way I can continue using BDDStepFactory2
and get the Junitresults to show either pass or fails?
EDIT:
The JunitResult is generating, however, this is what it looks like
...ANSWER
Answered 2021-Dec-27 at 22:06QUESTION
Presently I'm running API scenarios part of the Web scenario pack. When an API scenario fails (Eg. assert for a response status), I can see the screenshot of the browser attached with the failure in the QAF report. The screenshot is taken from the open browser from another scenario. I have noticed this issue after upgrading from QAF version 3.0.0 to 3.0.1. Not sure whether it is QAF framework issue/bug or whether I'm doing something wrong here.
If it is a known QAF issue, any temporary hacks will be very helpful.
Below is the snippet of test-results JSON from QAF:
...ANSWER
Answered 2021-Dec-07 at 03:37By design if there is active browser session, qaf will capture screenshot depending on the selenium.failure.screenshots
and selenium.success.screenshots
properties value. In your case, most probably it is because there is browser open while performing web services steps as per design screenshot attached in the report.
However it should have same behavior for same test with qaf version 3.0.0
and 3.0.1
. If you found that the same test/suite has different behavior with different versions (3.0.0
and 3.0.1
) of qaf, that should be reported to qaf project issue tracker.
QUESTION
I have created a custom step in which I'm doing some calculations. I need to pass or fail the step according to the outcome of the calculations. Presently step always shows pass in the report even when the calculation fails. Also, I would like to know how to pass the fail note to the report as I can see it is implemented in common steps.
I'm using QAF version 3.0.1
Below is a sample example:
...ANSWER
Answered 2021-Dec-07 at 02:44I was able to figure out the answer.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install qaf
You can use qaf like any standard Java library. Please include the the jar files in your classpath. You can also use any IDE and you can run and debug the qaf component as you would do with any other Java program. Best practice is to use a build tool that supports dependency management such as Maven or Gradle. For Maven installation, please refer maven.apache.org. For Gradle installation, please refer gradle.org .
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page