Skip to content
This repository has been archived by the owner on Feb 27, 2022. It is now read-only.

Can we nest testing scenarios? #12

Closed
outluch opened this issue Nov 6, 2017 · 2 comments
Closed

Can we nest testing scenarios? #12

outluch opened this issue Nov 6, 2017 · 2 comments
Assignees

Comments

@outluch
Copy link

outluch commented Nov 6, 2017

Look at example:
Mocha
In Mocha it is

describe('module name', () => {
  describe('when condition', () => {
    it('should de what is expected', () => {
      assert(1,1)
    })
  })
} )
@thetutlage
Copy link
Member

The idea is to keep them flat. Bunch of users has reported weird issues with nesting and even proposed Eslint rules for avoiding nesting.

lo1tuma/eslint-plugin-mocha#103
avajs/ava#62
avajs/ava#222

Again it's better to have 2 files over having one file with nesting all the place. KISS approach

@thetutlage thetutlage self-assigned this Nov 7, 2017
@outluch
Copy link
Author

outluch commented Nov 7, 2017

Ok, I will rely on your and community experience. I am new to automateed testing. Thanks for pointing out.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants