github
856 of 913 branches covered (93.76%)
108 of 280 new or added lines in 20 files covered. (38.57%)
4683 of 5110 relevant lines covered (91.64%)
64299.6 hits per line
|
export function whatBump (commits) { |
3✔ |
NEW
|
let level = 2
|
× |
NEW
|
let breakings = 0
|
× |
NEW
|
let features = 0
|
× |
NEW
|
|
× |
NEW
|
commits.forEach(commit => { |
× |
NEW
|
if (!commit.tag) return |
× |
NEW
|
|
× |
NEW
|
if (commit.tag.toLowerCase() === 'breaking') { |
× |
NEW
|
breakings += 1
|
× |
NEW
|
level = 0
|
× |
NEW
|
} else if (commit.tag.toLowerCase() === 'new') { |
× |
NEW
|
features += 1
|
× |
NEW
|
if (level === 2) { |
× |
NEW
|
level = 1
|
× |
NEW
|
} |
× |
NEW
|
} |
× |
NEW
|
}) |
× |
NEW
|
|
× |
NEW
|
return {
|
× |
NEW
|
level, |
× |
NEW
|
reason: `There are ${breakings} breaking changes and ${features} features` |
× |
NEW
|
} |
× |
NEW
|
} |
× |