memory-cards / rfcs

1 stars 0 forks source link

Config coverage for tests #6

Open Space647 opened 6 years ago

Space647 commented 6 years ago

I think need add code coverage and added lock for merge if coverage <50%. It's will help us for starting writing test

vvscode commented 6 years ago

Not sure that 50% is good idea

File                      |  % Stmts | % Branch |  % Funcs |  % Lines | Uncovered Line #s |
--------------------------|----------|----------|----------|----------|-------------------|
All files                 |    97.92 |      100 |    94.12 |      100 |                   |
 cards-exporter           |      100 |      100 |      100 |      100 |                   |
  enzyme.js               |      100 |      100 |      100 |      100 |                   |
 cards-exporter/api/cards |      100 |      100 |      100 |      100 |                   |
  listCards.ts            |      100 |      100 |      100 |      100 |                   |
  updateCards.ts          |      100 |      100 |      100 |      100 |                   |
 cards-exporter/api/date  |      100 |      100 |      100 |      100 |                   |
  index.ts                |      100 |      100 |      100 |      100 |                   |
 cards-exporter/pages     |      100 |      100 |      100 |      100 |                   |
  index.tsx               |      100 |      100 |      100 |      100 |                   |
 cards-exporter/utils     |       96 |      100 |     87.5 |      100 |                   |
  cards.ts                |    94.44 |      100 |    83.33 |      100 |                   |
  env.ts                  |      100 |      100 |      100 |      100 |                   |
--------------------------|----------|----------|----------|----------|-------------------|
vvscode commented 6 years ago

what about https://coveralls.io/ ?

Space647 commented 6 years ago

I'm not against about coveralls.io. Maybe 30% for lock ?

StolpnerA commented 6 years ago

@Space647 Why 30 or 50, when we have at the moment 90+%? I think should be code coverage 75-80+%

Space647 commented 6 years ago

@StolpnerA .I don't mind raising increase coverage, i think it's idea @vvscode

Space647 commented 6 years ago

@vvscode , @StolpnerA so add 80% or 90%?

vvscode commented 6 years ago

95%

vvscode commented 6 years ago

at coveralls, you could just define percentage to decrease existing coverage. We could keep it 1-2%

StolpnerA commented 6 years ago

@Space647 No, pls, not 90%, it's very much, I don't want write tests :)

Space647 commented 6 years ago

Ok, if you agree with me , i do 85% ? @vvscode @StolpnerA

vvscode commented 6 years ago

as you wish. I see no point in not writing tests

More than that, I'm ready add more tests after with finish choosing tech stack

StolpnerA commented 6 years ago

@vvscode Okay, a agree with you, tests it's good. But I can not force myself to love to write tests or I do not understand through how to write them )) May be it's good moment understanding them? )) @Space647 insist on 95% persuaded :)

zenby commented 6 years ago

To sum up so we decided to set 95% of allowed test coverage percentage. If new PR have smaller percentage it's won't be allowed to merge it into master, will it? Is the only available characteristic that gives us codecov that should be implemented?

vvscode commented 6 years ago

it won't

About stats for control - that's for investigation for the one who is going to do. Jest itself supports more metrics (branches, files, lines and so on)

Space647 commented 6 years ago

@vvscode Hmm ... if l all understand not need blocking merge if coverage <95?

vvscode commented 6 years ago

Why not?