Skip to content

cmd/geth: cover attach header flag order in test#34111

Open
0xWeakSheep wants to merge 1 commit intoethereum:masterfrom
0xWeakSheep:fix/attach-header-order
Open

cmd/geth: cover attach header flag order in test#34111
0xWeakSheep wants to merge 1 commit intoethereum:masterfrom
0xWeakSheep:fix/attach-header-order

Conversation

@0xWeakSheep
Copy link
Copy Markdown

Summary

This PR updates TestAttachWithHeaders to cover both accepted flag orders for custom RPC headers in geth attach:

  • geth attach -H "first: one" -H "second: two" <endpoint>
  • geth -H "first: one" -H "second: two" attach <endpoint>

The previous test only executed the first form and kept the second as a commented follow-up note. This change turns the second form into an active assertion.

Why

This makes the expected CLI behavior explicit and protected by test coverage, so future flag parsing changes won't regress either invocation style.

Testing

  • go test ./cmd/geth -run TestAttachWithHeaders -count=1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant