mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-28 07:36:44 +00:00
20 lines
285 B
Go
20 lines
285 B
Go
package cli
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
)
|
|
|
|
func TestCodeBlock(t *testing.T) {
|
|
t.Parallel()
|
|
assert := assert.New(t)
|
|
|
|
lines := []string{
|
|
"abc",
|
|
"bcd",
|
|
}
|
|
|
|
expected := "```\n" + "abc\n" + "bcd\n" + "```"
|
|
assert.Equal(expected, CodeBlock(lines))
|
|
}
|