Skip to content
This repository was archived by the owner on Sep 11, 2020. It is now read-only.

blame code reorganization, and mutting the test #9

Merged
merged 1 commit into from
Dec 12, 2015
Merged

blame code reorganization, and mutting the test #9

merged 1 commit into from
Dec 12, 2015

Conversation

mcuadros
Copy link
Contributor

This PRs conatins:

  • blame and revlist packages has been removed.
  • Cleanup of the packages revlist and blame now the main entry function are attached to Commit as we agreed.
  • The RevList was removed, now is returned a simple list of Commit and a function SortCommits has made public
  • The function CountLines now is private
  • And the test are not verbose

@alcortesm why we have a small bash files on the repo?

@codecov-io
Copy link

Current coverage is 68.39%

Merging #9 into v2.0.0 will decrease coverage by -1.26% as of 81c478f

@@            v2.0.0      #9   diff @@
======================================
  Files           15      17     +2
  Stmts          926    1199   +273
  Branches       147     190    +43
  Methods          0       0       
======================================
+ Hit            645     820   +175
- Partial         72      92    +20
- Missed         209     287    +78

Review entire Coverage Diff as of 81c478f

Powered by Codecov. Updated on successful CI builds.

@alcortesm
Copy link
Contributor

LGTM.

Very nice cleanup!

@mcuadros those small bash scripts generate go code to help testing the blame: more precisely they generate the elements of the blameTests slice, which are quite painful to generate by hand. For example, they generate things like this:

    {"https://github.com/spinnaker/spinnaker.git", "f39d86f59a0781f130e8de6b2115329c1fbe9545", "pylib/spinnaker/validate_configuration.py", concat(
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 29),
        repeat("1e3d328a2cabda5d0aaddc5dec65271343e0dc37", 19),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 15),
        repeat("b5d999e2986e190d81767cd3cfeda0260f9f6fb8", 1),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 12),
        repeat("1e14f94bcf82694fdc7e2dcbbfdbbed58db0f4d9", 1),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 4),
        repeat("b5d999e2986e190d81767cd3cfeda0260f9f6fb8", 8),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 1),
        repeat("b5d999e2986e190d81767cd3cfeda0260f9f6fb8", 4),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 46),
        repeat("1e14f94bcf82694fdc7e2dcbbfdbbed58db0f4d9", 1),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 4),
        repeat("1e3d328a2cabda5d0aaddc5dec65271343e0dc37", 42),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 1),
        repeat("1e3d328a2cabda5d0aaddc5dec65271343e0dc37", 1),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 3),
        repeat("1e3d328a2cabda5d0aaddc5dec65271343e0dc37", 1),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 1),
        repeat("1e14f94bcf82694fdc7e2dcbbfdbbed58db0f4d9", 8),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 1),
        repeat("1e14f94bcf82694fdc7e2dcbbfdbbed58db0f4d9", 2),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 3),
        repeat("1e3d328a2cabda5d0aaddc5dec65271343e0dc37", 3),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 12),
        repeat("1e14f94bcf82694fdc7e2dcbbfdbbed58db0f4d9", 10),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 69),
        repeat("b5d999e2986e190d81767cd3cfeda0260f9f6fb8", 7),
        repeat("a24001f6938d425d0e7504bdf5d27fc866a85c3d", 4),
    )},

You can get rid of them if you want, I will keep them around in my computer for future blame testing.

@alcortesm
Copy link
Contributor

Just to clarify my last post;

  1. Removing the bash scripts is safe and will not break the code.
  2. Removing the bash scripts will not make testing the current code any harder, either.
  3. Removing the bash scripts will make adding more tests to the blame implementation more painful, though.

mcuadros added a commit that referenced this pull request Dec 12, 2015
blame code reorganization, and mutting the test
@mcuadros mcuadros merged commit b7304b2 into src-d:v2.0.0 Dec 12, 2015
mcuadros added a commit that referenced this pull request Jan 31, 2017
blame code reorganization, and mutting the test
gsalingu-ovhus pushed a commit to gsalingu-ovhus/go-git that referenced this pull request Mar 28, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants