mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-08-06 22:33:07 +02:00
Add tests for tag information rendering
These should have been added when we started rendering this information in e5b09f34e0; apparently I was too lazy back then. Adding them now to guard against breaking it in the next commit. I'm adding these to the CRUD tests, it doesn't seem worth adding separate tests just for these assertions.
This commit is contained in:
@ -32,6 +32,18 @@ var CrudAnnotated = NewIntegrationTest(NewIntegrationTestArgs{
|
|||||||
Lines(
|
Lines(
|
||||||
MatchesRegexp(`new-tag.*message`).IsSelected(),
|
MatchesRegexp(`new-tag.*message`).IsSelected(),
|
||||||
).
|
).
|
||||||
|
Tap(func() {
|
||||||
|
t.Views().Main().ContainsLines(
|
||||||
|
Equals("Annotated tag: new-tag"),
|
||||||
|
Equals(""),
|
||||||
|
Contains("Tagger:"),
|
||||||
|
Contains("TaggerDate:"),
|
||||||
|
Equals(""),
|
||||||
|
Equals("message"),
|
||||||
|
Equals(""),
|
||||||
|
Equals("---"),
|
||||||
|
)
|
||||||
|
}).
|
||||||
Press(keys.Universal.Push).
|
Press(keys.Universal.Push).
|
||||||
Tap(func() {
|
Tap(func() {
|
||||||
t.ExpectPopup().Prompt().
|
t.ExpectPopup().Prompt().
|
||||||
|
@ -28,6 +28,13 @@ var CrudLightweight = NewIntegrationTest(NewIntegrationTestArgs{
|
|||||||
Lines(
|
Lines(
|
||||||
MatchesRegexp(`new-tag.*initial commit`).IsSelected(),
|
MatchesRegexp(`new-tag.*initial commit`).IsSelected(),
|
||||||
).
|
).
|
||||||
|
Tap(func() {
|
||||||
|
t.Views().Main().ContainsLines(
|
||||||
|
Equals("Lightweight tag: new-tag"),
|
||||||
|
Equals(""),
|
||||||
|
Equals("---"),
|
||||||
|
)
|
||||||
|
}).
|
||||||
PressEnter().
|
PressEnter().
|
||||||
Tap(func() {
|
Tap(func() {
|
||||||
// view the commits of the tag
|
// view the commits of the tag
|
||||||
|
Reference in New Issue
Block a user