Skip to content

Commit

Permalink
ci: add benchmark test for Style.Render
Browse files Browse the repository at this point in the history
  • Loading branch information
muesli committed Apr 7, 2022
1 parent 6b5dc18 commit a86f21a
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions style_test.go
@@ -0,0 +1,15 @@
package lipgloss

import (
"testing"
)

func BenchmarkStyleRender(b *testing.B) {
s := NewStyle().
Bold(true).
Foreground(Color("#ffffff"))

for i := 0; i < b.N; i++ {
s.Render("Hello world")
}
}

0 comments on commit a86f21a

Please sign in to comment.