Skip to content

Latest commit

 

History

History
25 lines (19 loc) · 523 Bytes

VDR106.md

File metadata and controls

25 lines (19 loc) · 523 Bytes

VDR106. Scenario should have only one subject

Several subjects in one scenario could confuse both scenario author and scenario reviewers.

❌ Anti-pattern

# scenarios/register_user.py
class Scenario(vedro.Scenario):
    subject = "register"
    subject = "register new user"

    def when(self)
      self.response = ...

✅ Best practice

# scenarios/register_user.py
class Scenario(vedro.Scenario):
    subject = "register new user"

    def when(self)
      self.response = ...