Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tests for babel-generator #5845

Merged
merged 1 commit into from
Jun 10, 2017

Conversation

1egoman
Copy link
Contributor

@1egoman 1egoman commented Jun 10, 2017

Q A
Patch: Bug Fix? no
Major: Breaking Change? no
Minor: New Feature? no
Deprecations? no
Spec Compliancy? yes
Tests Added/Pass? yes
Fixed Tickets #5326
License MIT
Doc PR no
Dependency Changes no

Added two tests for src/generators/flow.js that check if a value is of
type empty or mixed. The goal was to cover https://codecov.io/gh/babel/babel/src/master/packages/babel-generator/src/generators/flow.js#L172 and https://codecov.io/gh/babel/babel/src/master/packages/babel-generator/src/generators/flow.js#L176, and after running ./scripts/test-cov.sh locally I confirm those lines are now covered.

Added two tests for src/generators/flow.js that check if a value is of
type `empty` or `mixed`.
@mention-bot
Copy link

@1egoman, thanks for your PR! By analyzing the history of the files in this pull request, we identified @ChauTNguyen, @bhosmer and @sugargreenbean to be potential reviewers.

@codecov
Copy link

codecov bot commented Jun 10, 2017

Codecov Report

Merging #5845 into 7.0 will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##              7.0    #5845   +/-   ##
=======================================
  Coverage   85.21%   85.21%           
=======================================
  Files         284      284           
  Lines        9958     9958           
  Branches     2780     2780           
=======================================
  Hits         8486     8486           
  Misses        971      971           
  Partials      501      501
Impacted Files Coverage Δ
packages/babel-helper-call-delegate/src/index.js 64% <0%> (-4%) ⬇️
packages/babel-traverse/src/path/context.js 85.34% <0%> (-1.73%) ⬇️
packages/babel-traverse/src/path/modification.js 72.11% <0%> (-0.97%) ⬇️
packages/babel-traverse/src/visitors.js 85.71% <0%> (-0.96%) ⬇️
...bel-plugin-transform-es2015-classes/src/vanilla.js 91.06% <0%> (+0.42%) ⬆️
packages/babel-generator/src/generators/flow.js 99.26% <0%> (+1.47%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cce83a0...1ab5fb2. Read the comment docs.

@1egoman
Copy link
Contributor Author

1egoman commented Jun 10, 2017

Looking at the coverage report above, it looks like the lines I intended to cover are covered:

screen shot 2017-06-10 at 6 17 27 am

Did I go about covering those lines in the right way?

@hzoo hzoo added area: tests PR: Internal 🏠 A type of pull request used for our changelog categories labels Jun 10, 2017
@hzoo
Copy link
Member

hzoo commented Jun 10, 2017

Yep, good work!

@hzoo hzoo merged commit 070662e into babel:7.0 Jun 10, 2017
@1egoman 1egoman deleted the babel-generator-tests-empty-mixed branch June 10, 2017 13:57
1egoman added a commit to 1egoman/babel that referenced this pull request Jun 10, 2017
Added two tests for src/generators/flow.js that check if a value is of
type `empty` or `mixed`.
@lock lock bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label Oct 6, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Oct 6, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area: tests outdated A closed issue/PR that is archived due to age. Recommended to make a new issue PR: Internal 🏠 A type of pull request used for our changelog categories
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants