@@ -368,25 +368,26 @@ func TestProfilesRoundTrip(t *testing.T) {
368368
369369func CreateTestProfiles () pprofile.Profiles {
370370 profiles := pprofile .NewProfiles ()
371+ dic := profiles .ProfilesDictionary ()
371372 resource := profiles .ResourceProfiles ().AppendEmpty ()
372373 scope := resource .ScopeProfiles ().AppendEmpty ()
373374 profile := scope .Profiles ().AppendEmpty ()
374375
375- profile .StringTable ().Append ("samples" , "count" , "cpu" , "nanoseconds" )
376+ dic .StringTable ().Append ("samples" , "count" , "cpu" , "nanoseconds" )
376377 st := profile .SampleType ().AppendEmpty ()
377378 st .SetTypeStrindex (0 )
378379 st .SetUnitStrindex (1 )
379380 pt := profile .PeriodType ()
380381 pt .SetTypeStrindex (2 )
381382 pt .SetUnitStrindex (3 )
382383
383- a := profile .AttributeTable ().AppendEmpty ()
384+ a := dic .AttributeTable ().AppendEmpty ()
384385 a .SetKey ("process.executable.build_id.htlhash" )
385386 a .Value ().SetStr ("600DCAFE4A110000F2BF38C493F5FB92" )
386- a = profile .AttributeTable ().AppendEmpty ()
387+ a = dic .AttributeTable ().AppendEmpty ()
387388 a .SetKey ("profile.frame.type" )
388389 a .Value ().SetStr ("native" )
389- a = profile .AttributeTable ().AppendEmpty ()
390+ a = dic .AttributeTable ().AppendEmpty ()
390391 a .SetKey ("host.id" )
391392 a .Value ().SetStr ("localhost" )
392393
@@ -396,10 +397,10 @@ func CreateTestProfiles() pprofile.Profiles {
396397 sample .TimestampsUnixNano ().Append (0 )
397398 sample .SetLocationsLength (1 )
398399
399- m := profile .MappingTable ().AppendEmpty ()
400+ m := dic .MappingTable ().AppendEmpty ()
400401 m .AttributeIndices ().Append (0 )
401402
402- l := profile .LocationTable ().AppendEmpty ()
403+ l := dic .LocationTable ().AppendEmpty ()
403404 l .SetMappingIndex (0 )
404405 l .SetAddress (111 )
405406 l .AttributeIndices ().Append (1 )
0 commit comments