File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -39,10 +39,20 @@ test.afterEach((ctx) => {
3939 removeMatchedModules ( / c u s t o m - t o o l \. j s $ / )
4040} )
4141
42- test ( 'should log tracking metrics' , function ( t ) {
43- const { agent } = t . nr
42+ test ( 'should log tracking metrics' , function ( t , end ) {
43+ t . plan ( 5 )
44+ const { agent, tool, input } = t . nr
4445 const { version } = require ( '@langchain/core/package.json' )
45- assertPackageMetrics ( { agent, pkg : '@langchain/core' , version } )
46+ helper . runInTransaction ( agent , async ( ) => {
47+ await tool . call ( input )
48+ assertPackageMetrics ( {
49+ agent,
50+ pkg : '@langchain/core' ,
51+ version,
52+ subscriberType : true
53+ } , { assert : t . assert } )
54+ end ( )
55+ } )
4656} )
4757
4858test ( 'should create span on successful tools create' , ( t , end ) => {
You can’t perform that action at this time.
0 commit comments