@@ -8,10 +8,11 @@ import (
88 "strings"
99 "testing"
1010
11- "github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard/reports"
12- "github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard/utils"
1311 "github.com/stretchr/testify/assert"
1412 "github.com/stretchr/testify/require"
13+
14+ "github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard/reports"
15+ "github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard/utils"
1516)
1617
1718var (
@@ -256,6 +257,8 @@ func TestRun(t *testing.T) {
256257
257258 for _ , tc := range testCases {
258259 t .Run (tc .name , func (t * testing.T ) {
260+ t .Parallel ()
261+
259262 testResults , err := tc .runner .RunTestPackages ([]string {flakyTestPackagePath })
260263 require .NoError (t , err )
261264
@@ -538,7 +541,7 @@ func TestAttributePanicToTest(t *testing.T) {
538541 "\t /opt/hostedtoolcache/go/1.24.0/x64/src/testing/testing.go:1851 +0x413" ,
539542 " logger.go:146: 03:14:04.485880684\t INFO\t Deployed KeystoneForwarder 1.0.0 chain selector 909606746561742123 addr 0x72B66019aCEdc35F7F6e58DF94De95f3cBCC5971\t {\" version\" : \" (devel)@unset\" }" ,
540543 " logger.go:146: 03:14:04.486035865\t INFO\t deploying forwarder\t {\" version\" : \" (devel)@unset\" , \" chainSelector\" : 5548718428018410741}" ,
541- " logger.go:146: 2025-03-08T03:14:04.490Z\t INFO\t changeset/jd_register_nodes.go:91\t registered node\t {\" version\" : \" unset@unset\" , \" name\" : \" node1\" , \" id\" : \" node:{id:\\ \" 895776f5ba0cc11c570a47b5cc3dbb8771da9262cfb545cd5d48251796af7f1d \\ \" public_key:\\ \" 895776f5ba0cc11c570a47b5cc3dbb8771da9262cfb545cd5d48251796af7f1d \\ \" is_enabled:true is_connected:true labels:{key:\\ \" product\\ \" value:\\ \" test-product\\ \" } labels:{key:\\ \" environment\\ \" value:\\ \" test-env\\ \" } labels:{key:\\ \" nodeType\\ \" value:\\ \" bootstrap\\ \" } labels:{key:\\ \" don-0-don1\\ \" }\" }" ,
544+ " logger.go:146: 2025-03-08T03:14:04.490Z\t INFO\t changeset/jd_register_nodes.go:91\t registered node\t {\" version\" : \" unset@unset\" , \" name\" : \" node1\" , \" id\" : \" node:{id:\\ \" 895776f5ba0cc11c570a47b5cc3dbb8771da9262cfb545cd5d48251796af7f \\ \" public_key:\\ \" 895776f5ba0cc11c570a47b5cc3dbb8771da9262cfb545cd5d48251796af7f \\ \" is_enabled:true is_connected:true labels:{key:\\ \" product\\ \" value:\\ \" test-product\\ \" } labels:{key:\\ \" environment\\ \" value:\\ \" test-env\\ \" } labels:{key:\\ \" nodeType\\ \" value:\\ \" bootstrap\\ \" } labels:{key:\\ \" don-0-don1\\ \" }\" }" ,
542545 },
543546 },
544547 {
@@ -550,9 +553,7 @@ func TestAttributePanicToTest(t *testing.T) {
550553 }
551554
552555 for _ , tc := range testCases {
553- tc := tc // capture range variable
554556 t .Run (tc .name , func (t * testing.T ) {
555- t .Parallel ()
556557 testName , timeout , err := attributePanicToTest (tc .outputs )
557558 assert .Equal (t , tc .expectedTimeout , timeout , "timeout flag mismatch" )
558559 if tc .expectedTestName == "" {
@@ -565,6 +566,63 @@ func TestAttributePanicToTest(t *testing.T) {
565566 }
566567}
567568
569+ func TestFailToAttributePanicToTest (t * testing.T ) {
570+ t .Parallel ()
571+
572+ testCases := []struct {
573+ name string
574+ outputs []string
575+ }{
576+ {
577+ name : "no test name in panic" ,
578+ outputs : []string {
579+ "panic: reflect: Elem of invalid type bool" ,
580+ "goroutine 104182 [running]:" ,
581+ "reflect.elem(0xc0569d9998?)" ,
582+ "\t /opt/hostedtoolcache/go/1.24.0/x64/src/reflect/type.go:733 +0x9a" ,
583+ "reflect.(*rtype).Elem(0xa4dd940?)" ,
584+ "\t /opt/hostedtoolcache/go/1.24.0/x64/src/reflect/type.go:737 +0x15" ,
585+ "github.com/smartcontractkit/chainlink-solana/pkg/solana/chainreader.setPollingFilterOverrides(0x0, {0xc052040510, 0x1, 0xc?})" ,
586+ "\t /home/runner/go/pkg/mod/github.com/smartcontractkit/[email protected] /pkg/solana/chainreader/chain_reader.go:942 +0x492" ,
587+ "github.com/smartcontractkit/chainlink-solana/pkg/solana/chainreader.(*ContractReaderService).addEventRead(_, _, {_, _}, {_, _}, {{0xc0544c4270, 0x9}, {0xc0544c4280, 0xc}, ...}, ...)" ,
588+ "\t /home/runner/go/pkg/mod/github.com/smartcontractkit/[email protected] /pkg/solana/chainreader/chain_reader.go:605 +0x13d" ,
589+ "github.com/smartcontractkit/chainlink-solana/pkg/solana/chainreader.(*ContractReaderService).initNamespace(0xc054472540, 0xc01c37d440?)" ,
590+ "\t /home/runner/go/pkg/mod/github.com/smartcontractkit/[email protected] /pkg/solana/chainreader/chain_reader.go:443 +0x28b" ,
591+ "github.com/smartcontractkit/chainlink-solana/pkg/solana/chainreader.NewContractReaderService({0x7fcf8b532040?, 0xc015b223e0?}, {0xc6ac960, 0xc05464e470}, {0xc0544384e0?, {0xc01c37d440?, 0xc054163b84?, 0xc054163b80?}}, {0x7fcf8071c7a0, 0xc0157928c0})" ,
592+ "\t /home/runner/go/pkg/mod/github.com/smartcontractkit/[email protected] /pkg/solana/chainreader/chain_reader.go:97 +0x287" ,
593+ "github.com/smartcontractkit/chainlink-solana/pkg/solana.(*Relayer).NewContractReader(0xc015b2e150, {0x4d0102030cb384f5?, 0xb938300b5ca1aa13?}, {0xc05469c000, 0x1eedf, 0x20000})" ,
594+ "\t /home/runner/go/pkg/mod/github.com/smartcontractkit/[email protected] /pkg/solana/relay.go:160 +0x205" ,
595+ "github.com/smartcontractkit/chainlink/v2/core/capabilities/ccip/oraclecreator.(*pluginOracleCreator).createReadersAndWriters(_, {_, _}, {_, _}, _, {0x3, {0x0, 0xa, 0x93, ...}, ...}, ...)" ,
596+ "\t /home/runner/work/chainlink/chainlink/core/capabilities/ccip/oraclecreator/plugin.go:446 +0x338" ,
597+ "github.com/smartcontractkit/chainlink/v2/core/capabilities/ccip/oraclecreator.(*pluginOracleCreator).Create(0xc033a69ad0, {0xc6f5a10, 0xc02e4f9a40}, 0x3, {0x3, {0x0, 0xa, 0x93, 0x8f, 0x67, ...}, ...})" ,
598+ "\t /home/runner/work/chainlink/chainlink/core/capabilities/ccip/oraclecreator/plugin.go:215 +0xc0c" ,
599+ "github.com/smartcontractkit/chainlink/v2/core/capabilities/ccip/launcher.createDON({0xc6f5a10, 0xc02e4f9a40}, {0x7fcf8b533ad0, 0xc015b97340}, {0xb6, 0x5e, 0x31, 0xd0, 0x35, 0xef, ...}, ...)" ,
600+ "\t /home/runner/work/chainlink/chainlink/core/capabilities/ccip/launcher/launcher.go:367 +0x451" ,
601+ "github.com/smartcontractkit/chainlink/v2/core/capabilities/ccip/launcher.(*launcher).processAdded(0xc015723080, {0xc6f5a10, 0xc02e4f9a40}, 0xc053de2ff0)" ,
602+ "\t /home/runner/work/chainlink/chainlink/core/capabilities/ccip/launcher/launcher.go:254 +0x239" ,
603+ "github.com/smartcontractkit/chainlink/v2/core/capabilities/ccip/launcher.(*launcher).processDiff(0xc015723080, {0xc6f5a10, 0xc02e4f9a40}, {0xc053de2ff0?, 0xc053de3020?, 0xc053de3050?})" ,
604+ "\t /home/runner/work/chainlink/chainlink/core/capabilities/ccip/launcher/launcher.go:192 +0x68" ,
605+ "github.com/smartcontractkit/chainlink/v2/core/capabilities/ccip/launcher.(*launcher).tick(0xc015723080, {0xc6f5a10, 0xc02e4f9a40})" ,
606+ "\t /home/runner/work/chainlink/chainlink/core/capabilities/ccip/launcher/launcher.go:178 +0x20b" ,
607+ "github.com/smartcontractkit/chainlink/v2/core/capabilities/ccip/launcher.(*launcher).monitor(0xc015723080)" ,
608+ "\t /home/runner/work/chainlink/chainlink/core/capabilities/ccip/launcher/launcher.go:152 +0x112" ,
609+ "created by github.com/smartcontractkit/chainlink/v2/core/capabilities/ccip/launcher.(*launcher).Start.func1 in goroutine 1335" ,
610+ "\t /home/runner/work/chainlink/chainlink/core/capabilities/ccip/launcher/launcher.go:134 +0xa5" ,
611+ "FAIL\t github.com/smartcontractkit/chainlink/deployment/ccip/changeset/solana\t 184.801s" ,
612+ },
613+ },
614+ }
615+
616+ for _ , tc := range testCases {
617+ t .Run (tc .name , func (t * testing.T ) {
618+ testName , timeout , err := attributePanicToTest (tc .outputs )
619+ require .Error (t , err )
620+ assert .Empty (t , testName , "test name should be empty" )
621+ assert .False (t , timeout , "timeout flag should be false" )
622+ })
623+ }
624+ }
625+
568626func TestAttributeRaceToTest (t * testing.T ) {
569627 t .Parallel ()
570628
@@ -598,8 +656,6 @@ func TestAttributeRaceToTest(t *testing.T) {
598656 for _ , testCase := range testCases {
599657 tc := testCase
600658 t .Run (tc .name , func (t * testing.T ) {
601- t .Parallel ()
602-
603659 testName , err := attributeRaceToTest (tc .packageName , tc .raceEntries )
604660 if tc .expectedTestName == "" {
605661 require .Error (t , err )
0 commit comments