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

E1771. [TLD] Refactor team.rb #1043

Merged
merged 16 commits into from Nov 12, 2017
Merged

Conversation

darshil0193
Copy link
Contributor

These are all the minor refactoring related to the file. The two tasks left are updating the tests and refactoring self.randomize_all_by_parent function by disintegrating it in other smaller function. We are planning to submit these in next 3 days (by updating this pull request and removing the WIP mark).

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.01%) to 50.84% when pulling 4f488b9 on darshil0193:refactor/team.rb into a26cf3a on expertiza:master.

@coveralls
Copy link

Coverage Status

Coverage decreased (-15.6%) to 35.285% when pulling 0ced4de on darshil0193:refactor/team.rb into a26cf3a on expertiza:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.1%) to 50.963% when pulling 0ced4de on darshil0193:refactor/team.rb into a26cf3a on expertiza:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.1%) to 50.985% when pulling 0ced4de on darshil0193:refactor/team.rb into a26cf3a on expertiza:master.

@darshil0193 darshil0193 changed the title [WIP] Refactor/team.rb E1771: Refactor team.rb Oct 27, 2017
srujanb and others added 10 commits October 27, 2017 18:42
Renaming get_node_type to node_type
Renaming get_author_names to author_names
Passing &:destroy to the each block for destroying the team
Using find_by instead of dynamic methods and where.first
Updating the tests in team_spec.rb
Dividing randomize_all_by_parent method into
multiple sub methods

Change done by sjbarai
@coveralls
Copy link

Coverage Status

Coverage increased (+0.1%) to 50.984% when pulling 01b3c75 on darshil0193:refactor/team.rb into 781e456 on expertiza:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.1%) to 50.978% when pulling d72e055 on darshil0193:refactor/team.rb into 781e456 on expertiza:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.1%) to 50.995% when pulling d72e055 on darshil0193:refactor/team.rb into 781e456 on expertiza:master.

@Winbobob Winbobob self-assigned this Nov 2, 2017
@Winbobob
Copy link
Member

Winbobob commented Nov 3, 2017

Hi team,

You refactoring looks good to me.

  • Please complete pending tests;
  • Please fix code climate issues as much as you can.

Thanks,
Zhewei

@darshil0193
Copy link
Contributor Author

Hi Zhewei,

Thanks for the update. We'll complete the tests and try to remove the code climate errors and update the pull request.

Thanks,
Darshil

Completed the remaining tests
@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 51.065% when pulling 8fe0ca5 on darshil0193:refactor/team.rb into 781e456 on expertiza:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 51.053% when pulling 18e3ea1 on darshil0193:refactor/team.rb into 781e456 on expertiza:master.

Removing some minor and straight forward codeclimate errors
@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 51.053% when pulling 6e1ceff on darshil0193:refactor/team.rb into 781e456 on expertiza:master.

Solved a few more codeclimate issues
@coveralls
Copy link

Coverage Status

Coverage decreased (-5.07%) to 45.778% when pulling a72388f on darshil0193:refactor/team.rb into 781e456 on expertiza:master.

Reverting to use of each instead of find_each
@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 51.031% when pulling bb30a4b on darshil0193:refactor/team.rb into 781e456 on expertiza:master.

@Winbobob Winbobob changed the title E1771: Refactor team.rb E1771. [TLD] Refactor team.rb Nov 12, 2017
end
end

def self.sort_teams_by_members_reverse(teams)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm, I don't think you need to extract one line of code as a new method. But it is not a big deal.

@Winbobob Winbobob merged commit bb30a4b into expertiza:master Nov 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants