Skip to content

test: add git edge-case test matrix #164

@rocketman-code

Description

@rocketman-code

Context

Parent: #160

15 git tests existed pre-v0.4.0 but missed annotated tags (#145) and branch names with slashes (#146). Tests covered the common cases (lightweight tags, simple branch names, SHAs) but not the edges that real-world git repos produce.

Expected Behavior

Systematic coverage of classify_diff_arg() and GitTreeVfs against a matrix of git ref types.

Scope

  • Annotated tags (git tag -a)
  • Lightweight tags
  • Branch names with slashes (feature/auth, fix/bug/123)
  • Detached HEAD
  • Short SHAs (7-char, full 40-char)
  • HEAD~N, HEAD^N syntax
  • Tags pointing to tags (peeled chain)
  • Ambiguous refs (file named "main" + branch named "main")
  • Empty repo (no commits)
  • Shallow clones (--depth 1)
  • GitTreeVfs reading files from various ref types

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Medium priorityenhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions