GithubHelp home page GithubHelp logo

Comments (9)

noronhaa avatar noronhaa commented on June 14, 2024

Hi @kishoreccaus

Glad you like the framework :)

If you are using the DebuggingRunner or a runner in general and executing from within an IDE then you can put the parameters in the 'VM options:' of the 'Edit Configurations...' section (this is how for IntelliJ, I am sure it would be similar if you use eclipse)

debuggingrunner driver config

Does this help?

from frameworkium-bdd.

kishoreccaus avatar kishoreccaus commented on June 14, 2024

Hi Noronhaa,
Thanks a lot for your response.

I tried this but still when I run a single feature by right clicking on the feature file and Run "Feature:FeatureName" my scripts fail with a null pointer exception. Pls refer to the attached screenshot for further details. Secondly is it possible to include the driver files in the project and point the path of the driver to that .exe file? Due to security constraints, I dont have firefox in my machine.
frameworkium driver issue

Another issue which I am facing is I created a new feature file and a corresponding steps file. When I click on the steps in the feature file they are pointing towards those steps in the Step Definition file, but when I execute them I get a error message as the steps haven't been implemented. I did create a glue folder and created the step definitions file in the glue folder as well and included in the Debugging runner file as well. Do we need to mention this in any other files as well?

from frameworkium-bdd.

noronhaa avatar noronhaa commented on June 14, 2024

The way frameworkium works is it hooks onto a runner, lets use the Debugging runner for example. When the runner is executed the frameworkium BaseTest code runs which sets up the driver. As you are clicking on the feature file to run it, the DebuggingRunner never runs and in turn the frameworkium BaseTest code is never run and so driver is never set up which is why later on you see driver = null

When debugging tests only use the debugging runner and have all the configs for feature file location and glue in that runner class. Then inject the external parameters such as browser and driver location into the VM options like shown before. Use cucumber tagging to only test a certain sceanrio or feature. put a tag eg @debug at the top of your feature file above the line Feature: ... then put that same tag in the Debugging Runner class tags = {"@debugg"},. Now when you run the debugging runner class it will take in the external parameters (webdriver location), run the code from frameworkiums BaseTest (setting up your driver) and run only the sceanrio or feature you want to run (by hooking onto your @debug tag or what ever you want to call it)

When running from the command line be sure to add the package of any new glue classes in the cucumber-jvm-parallel-plugin which is in the pom.xml

from frameworkium-bdd.

kishoreccaus avatar kishoreccaus commented on June 14, 2024

Hi Noronhaa,
Thanks for your responses which are definitely providing more clarity on the framework.

I tried adding the tags to the Debugging Runner class and the Debugging Configurations as mentioned by you in the earlier screenshots, but I am getting an exception as "(The system cannot find the file specified)" which I suspect is primarily it is not setting up the path of the driver correctly. Pls find below the screenshot for the same.
debuggingrunner issues

Secondly Could you also please help us with how to set aconfig file, becuase we are unable to make out exactly how to create and point a cofig file with all the properties. For e.,g. we would like to create a file similar to the FirefoxGrid.yaml file provided by you in the framework and mention all the properties in that file and we would like the properties like browser name, path of the driver etc., to be picked up by the framework from there during runtime.
how to setup a config file

from frameworkium-bdd.

noronhaa avatar noronhaa commented on June 14, 2024

Looks like you need a space between your file path and -Dbrowser=chromer as it thinks -Dbrowser=chrome is part fo the file path, what parameters are you using in VM Options ?

from frameworkium-bdd.

kishoreccaus avatar kishoreccaus commented on June 14, 2024

Thanks for correcting that Noronhaa. Now I am able to execute the tests using individual features. But could you pls help us to understand how to create a separate yaml file and how to point the framework to pick the properties values from that yaml file similar to the firefoxgrid.yaml file in your core project.

from frameworkium-bdd.

noronhaa avatar noronhaa commented on June 14, 2024

You should be able to parse -Dconfig=path/to/myyaml.yaml and it will register your yaml and load the configs from it

from frameworkium-bdd.

kishoreccaus avatar kishoreccaus commented on June 14, 2024

Hi Noronhaa,
I created a new config file called as "ChromeGrid.Yaml" and passed it along with the MVN command as but I am getting a runtime exception stating the config file could not be found. Could you pls refer to the attached screenshot and let me know what could be the issue.

cofig error

from frameworkium-bdd.

noronhaa avatar noronhaa commented on June 14, 2024

try -Dconfig=config/chromeGrid.yaml or -Dconfig=config\chromeGrid.yaml as I think it's the path from the resources folder

from frameworkium-bdd.

Related Issues (7)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.