Skip to content

Jurajzovinec/find-out-with-tdd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Find out with TDD

Small utility repo with out-of-box TDD environment tolerating failing cases. Tests are failing until one approach finally returns desired result.

describe("testing of approaches", () => {
  const EXPECTED_RESULT = "Ok"

  const tester = new ApproachesTester(EXPECTED_RESULT)

  afterAll(() => {
    tester.printResult()
    tester.verifyIfSomeApproachSucceed()
  })

  it.each`
    approach     | approachName
    ${approach1} | ${"First test approach"}
    ${approach2} | ${"Second test approach"}
    ${approach3} | ${"Third test approach"}
  `("should try run $approachName", async ({approach, approachName}) => {
    await tester.testApproach(approach, approachName)
  })
})

Setup

Install deps and run in debug mode:

How to

Here is some motivation embracing failures

1 2 3

About

Small utility repo

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published