✅Test: 测试结构体解析器
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
package agent
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/tmc/langchaingo/outputparser"
|
||||
)
|
||||
|
||||
func TestCard(t *testing.T) {
|
||||
definedCard, err := outputparser.NewDefined(Card{})
|
||||
|
||||
if err != nil {
|
||||
t.Fatalf("%v", err)
|
||||
}
|
||||
|
||||
output := definedCard.GetFormatInstructions()
|
||||
t.Log(output)
|
||||
}
|
||||
Reference in New Issue
Block a user