• @TheSlad
    link
    211 month ago

    Ive heard of stories where people would have an imposed test coverage percentage requirement… and they would just have a single dummy method that printed “.” to the console thousands of times. They then have a single test for that one method, and whenever their codebase grows to big, they add more lines to it so that the dummy method has enough lines to meet the test coverage requirement.

    • @xmunk
      link
      101 month ago

      Percentage of lines covered by tests is such a terrible metric.

      • @TheSlad
        link
        91 month ago

        All metrics are terrible when used for anything other than objective analysis

        • lad
          link
          fedilink
          English
          21 month ago

          Yeah, every metric that can be applied automatically ends up becoming useless if people are incentivized to break it