Best Tests for Gilded Rose Kata | Kent Beck’s Desiderata

Поділитися
Вставка
  • Опубліковано 14 жов 2024

КОМЕНТАРІ •

  • @nymann9242
    @nymann9242 2 місяці тому

    Great video, would've liked to have heard a mention about mutation testing (as you did in the older "Introducing the Gilded Rose Kata and writing test cases using Approval Tests") as it was a concept that I really think compliments approval testing as we want to make sure we don't change behavior only the strcuture.

    • @EmilyBache-tech-coach
      @EmilyBache-tech-coach  2 місяці тому

      Yes, mutation testing is a useful approach. Couldn't quite fit it into this video tho

  • @benoitmansoux9352
    @benoitmansoux9352 6 місяців тому

    Thank you for presenting that interesting technique based on the coverage. I used to write unit tests from the specs when doing this kata

    • @EmilyBache-tech-coach
      @EmilyBache-tech-coach  6 місяців тому

      You're not the only one doing it like that! Glad I could show you something new and interesting.

  •  6 місяців тому

    Nice video! I last weeks, I have been thinking about descriptive vs. prescriptive use of tests, and particularly in the style of testing I care for (exploratory), and and find that helps me with some of the discussions around what you use desiderata on in the video on "is this a good test". Expressing intent and capturing intent without really seeking to understand are fascinatingly different.

  • @NeloOnyiah
    @NeloOnyiah 6 місяців тому

    Great video - as always! This approach looks similar to property based testing (quickcheck et al). Have you considered that as an approach?

    • @EmilyBache-tech-coach
      @EmilyBache-tech-coach  6 місяців тому +1

      Yes you can use property based testing. There are some specific circumstances where that approach is really helpful.

  • @pierre-antoineguillaume98
    @pierre-antoineguillaume98 6 місяців тому

    I feel like these tests are a lot less readable.
    I don't mean the test code, which is very generic, but I can't use the tests anymore to understand what the code does, unless I parse in my head the meaning of each line, there decide if it is pertinent or discard it, then try and understand what the business rule means.
    I have to think a bit more and try it out for myself

    • @EmilyBache-tech-coach
      @EmilyBache-tech-coach  6 місяців тому +3

      When creating these tests I didn't need to invest any effort in understand the business rules which made them more writable, but of course that means I couldn't embed any understanding of the business rules in a test name. So no, you don't use these tests to understand what the code does, you use them to support refactoring.

    • @m13v2
      @m13v2 6 місяців тому

      like in 1) start with expressive tests which are hard to refactor, 2) add the permutation test and refactor against that, 3) come up with new expressive tests? because i guess those i want to have when some of the rules change?

    • @EmilyBache-tech-coach
      @EmilyBache-tech-coach  6 місяців тому +2

      As you refactor you'll begin to understand the code and it will be easier to add tests for new functionality and rule changes that describe what they test.

    • @pierre-antoineguillaume98
      @pierre-antoineguillaume98 6 місяців тому

      Do you have an implementation of the testing lib in php ? Or maybe a place I can contribute to one ?