Possibility to use Gherkin syntax in the Azure DevOps test cases

Ihor Chekanov 11 Reputation points
2022-08-02T11:03:41.627+00:00

Dear all,

My team is working on automotive testing of the current project. And we would like to use Gherkin syntax for our test cases.
Also, we are going to store our test cases in the Azure Test Plan.

Unfortunately, after reading documentation (https://learn.microsoft.com/en-us/azure/devops/test/?view=azure-devops), I don't see the possibility to use Gherkin syntax directly in test cases.

Could you answer please, is it possible to use Gherkin syntax directly in the test case of Azure Test Plan? If yes, how can we do it?

Community Center Not monitored
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Huub - 21 Reputation points
    2022-08-23T14:25:33.257+00:00

    @Ihor Chekanov I guess also without tooling, you can manually map things like this:

    • Feature: create a static Suite
    • Scenario: add as a test case
    • Background: use Shared steps for this
    • Given, When: add as as test case steps (leave expected results empty)
    • Then: either add this as Expected result to the last step in the test case, or add it as a seperate step

    Another way could be to write the Gherkin scripts in Specflow and publish those to PicklesDoc and leave it there.
    In Test Plan you could make Suites for the features and add Test Cases as scenario's, just like above. Instead of copy-pasting all the steps from Specflow/PickesDoc to Test Plan, simply put a link to the relevant Feature in PicklesDoc so testers can find it there for manual testing just in case they incidentally want to test manually.

    Personally, if I look at our functional testers, I believe it would be nice if one could write tests in Test Plan, e.g. like written above and then push/pull to Specflow. So a developer can create the code behind the steps in using his techniscal toolchain (VS/Visual Studio) and our functional testers can keep away from the technical tooling like VS. That way our testers can feel at home in Devops and developers feel at home in VS. However apparently a tool whach could have been helpful for that was depricated, see https://docs.specflow.org/projects/specflow-excel/en/latest/
    Not sure why it's no longer supported.
    You might also want to check this:
    https://support.specflow.org/hc/en-us/community/posts/360012819997-Support-for-SpecFlow-Excel-in-current-SpecFlow-versions

    4 people found this answer helpful.
    0 comments No comments

  2. Anna Xiu-MSFT 31,056 Reputation points Microsoft External Staff
    2022-08-02T12:31:52.867+00:00

    Hi @Ihor Chekanov ,

    Azure DevOps is currently not supported in the Microsoft Q&A, the supported products are listed over here https://learn.microsoft.com/en-us/answers/products (more to be added later on).
    You can ask in the dedicated Azure DevOps forum over here:
    https://developercommunity.visualstudio.com/report?space=21&entry=problem

    Thanks for your understanding.

    Sincerely,
    Anna
    *
    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.