Skip to content

Commit 1744bb1

Browse files
More lint/format
1 parent 2017338 commit 1744bb1

2 files changed

Lines changed: 4 additions & 5 deletions

File tree

go/e2e/testharness/helper.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,12 +60,13 @@ func GetNextEventOfType(session *copilot.Session, eventType copilot.SessionEvent
6060
errCh := make(chan error, 1)
6161

6262
unsubscribe := session.On(func(event copilot.SessionEvent) {
63-
if event.Type == eventType {
63+
switch event.Type {
64+
case eventType:
6465
select {
6566
case result <- &event:
6667
default:
6768
}
68-
} else if event.Type == copilot.SessionError {
69+
case copilot.SessionError:
6970
msg := "session error"
7071
if event.Data.Message != nil {
7172
msg = *event.Data.Message

python/e2e/test_session.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -267,9 +267,7 @@ async def test_should_abort_a_session(self, ctx: E2ETestContext):
267267

268268
# Send a message that will trigger a long-running shell command
269269
await session.send(
270-
{
271-
"prompt": "run the shell command 'sleep 100' (note this works on both bash and PowerShell)"
272-
}
270+
{"prompt": "run the shell command 'sleep 100' (works on bash and PowerShell)"}
273271
)
274272

275273
# Wait for the tool to start executing

0 commit comments

Comments
 (0)