Skip to content

Commit

Permalink
Add some tests for #469
Browse files Browse the repository at this point in the history
  • Loading branch information
scottchiefbaker committed Sep 18, 2024
1 parent 4958a1e commit 36dcfde
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/bugs.bats
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,9 @@ teardown_file() {
run printf "%s" "$output"
assert_line --index 3 --partial "@ height"
}

@test "ANSI Reset without the zero (#469)" {
output=$( load_fixture "ansi_reset_no_number" | $diff_so_fancy )
run printf "%s" "$output"
assert_line --index 5 --partial "History"
}
9 changes: 9 additions & 0 deletions test/fixtures/ansi_reset_no_number.diff
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
diff --git a/history.md b/history.md
index f6776e0..a6b4546 100644
--- a/history.md
+++ b/history.md
@@ -1,3 +1,3 @@
-## History
+## Historyz

`diff-so-fancy` started as [a commit in paulirish's dotfiles](https://github.com/paulirish/dotfiles/commit/6743b907ff586c28cd36e08d1e1c634e2968893e#commitcomment-13349456), which grew into a [standalone script](https://github.com/paulirish/dotfiles/blob/63cb8193b0e66cf80ab6332477f1f52c7fbb9311/bin/diff-so-fancy). Later, [@stevemao](https://github.com/stevemao) brought it into its [own repo](https://github.com/so-fancy/diff-so-fancy) (here), and gave it the room to mature. It's quickly grown into a [widely collaborative project](https://github.com/so-fancy/diff-so-fancy/graphs/contributors).

0 comments on commit 36dcfde

Please sign in to comment.