I have the problem, that we have a Project Suite now with 2 Projects Hybridmanager and Datamanager and the 2 projects are only different in a couple of tests.
The UI itself is the same except for a few changes therefore I would need a couple of my keyword tests for both Projects and a couple of keyword tests specific for the specific project.
Is there a way to make keyword tests global, so I dont have to manually go through the process of getting the Namemapping for both projects even tho they are identically and instead just use the test in both projects? Copy Paste doesnt work either, sadly (or I dont know how)
best regards
Solved! Go to Solution.
Please refer "Adding an existing keyword test" in Creating and Recording Keyword Tests. Hope that is what you are looking for.
Please refer "Adding an existing keyword test" in Creating and Recording Keyword Tests. Hope that is what you are looking for.
Additionally, you can do the same with NameMapping... you can add an existing NameMapping file to a project so that you can use it in both.
When adding the existing Namemapping am I able to manipulate the namemapping - as for the Hybridmanager there are a few things different than with the datamanager, even tho the test is the same, 1 or 2 items are different and when I change it it changes it in both namemappings.
Same for tests ... is there something like a hardcopy, which does not break my existing test when I add / remove something?
Your request was to make test cases and namemapping global for both projects. That means that they are shared between the two projects. If you want to avoid having changes in one impact the other, then you don't want global test cases and name mapping, you want each project to have their own.
To be truthful, the BEST practice is the former... it's better to not have duplicated code/namemapping if you can avoid it because if something DOES change, with shared files, you only need to change it once. What you're going to need to do is make your test cases and, perhaps, your NameMapping conditional (there is a conditional option in NameMapping) so that, depending upon what project you're running from, the tests are "smart" enough to account for it.
You can create a new blank keyword test in the second project and copy and paste the required (or all) keyword test steps from an existing test in the first project. But as @tristaanogre said, it can become a maintenance nightmare pretty quicky.
Subject | Author | Latest Post |
---|---|---|