Skip to content

Commit 0817de8

Browse files
committed
Fix rewind E2E formatting
Apply the Java, Python, and Rust formatters required by CI. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 91a7e2ab-88a5-4365-accf-cbea1e1391e9
1 parent e3efa1e commit 0817de8

4 files changed

Lines changed: 11 additions & 17 deletions

File tree

java/src/test/java/com/github/copilot/e2e/RewindIT.java

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,14 @@ void shouldRestoreTrackedFileAndConversation() throws Exception {
5858
Path filePath = ctx.getWorkDir().resolve(FILE_NAME);
5959

6060
try (CopilotClient client = ctx.createClient();
61-
CopilotSession session = client.createSession(new SessionConfig().setModel("claude-sonnet-4.5")
62-
.setEnableFileChangeTracking(true).setOnPermissionRequest(PermissionHandler.APPROVE_ALL))
61+
CopilotSession session = client
62+
.createSession(
63+
new SessionConfig().setModel("claude-sonnet-4.5").setEnableFileChangeTracking(true)
64+
.setOnPermissionRequest(PermissionHandler.APPROVE_ALL))
6365
.get(30, TimeUnit.SECONDS)) {
6466
AssistantMessageEvent response = session
65-
.sendAndWait(new MessageOptions()
66-
.setPrompt("Use the create tool to create " + FILE_NAME + " containing exactly "
67-
+ FILE_CONTENT
67+
.sendAndWait(new MessageOptions().setPrompt(
68+
"Use the create tool to create " + FILE_NAME + " containing exactly " + FILE_CONTENT
6869
+ ". After the tool succeeds, reply with exactly SDK_REWIND_DONE."),
6970
30_000)
7071
.get(60, TimeUnit.SECONDS);

python/e2e/test_rewind_e2e.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,7 @@ def _same_path(left: str | Path, right: str | Path) -> bool:
2929

3030

3131
class TestRewind:
32-
async def test_should_restore_tracked_file_and_conversation(
33-
self, ctx: E2ETestContext
34-
):
32+
async def test_should_restore_tracked_file_and_conversation(self, ctx: E2ETestContext):
3533
file_path = Path(ctx.work_dir) / FILE_NAME
3634
session = await ctx.client.create_session(
3735
model="claude-sonnet-4.5",

rust/tests/e2e.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@ mod permissions;
6666
mod pre_mcp_tool_call_hook;
6767
#[path = "e2e/provider_endpoint.rs"]
6868
mod provider_endpoint;
69+
#[path = "e2e/rewind.rs"]
70+
mod rewind;
6971
#[path = "e2e/rpc_additional_edge_cases.rs"]
7072
mod rpc_additional_edge_cases;
7173
#[path = "e2e/rpc_agent.rs"]
@@ -110,8 +112,6 @@ mod rpc_tasks_and_handlers;
110112
mod rpc_ui_ephemeral_query;
111113
#[path = "e2e/rpc_workspace_checkpoints.rs"]
112114
mod rpc_workspace_checkpoints;
113-
#[path = "e2e/rewind.rs"]
114-
mod rewind;
115115
#[path = "e2e/session.rs"]
116116
mod session;
117117
#[path = "e2e/session_config.rs"]

rust/tests/e2e/rewind.rs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -81,11 +81,7 @@ async fn should_restore_tracked_file_and_conversation() {
8181
assert!(!file_path.exists());
8282

8383
let events = session.get_events().await.expect("get events after rewind");
84-
assert!(
85-
events
86-
.iter()
87-
.all(|event| event.id != rewind_point.event_id)
88-
);
84+
assert!(events.iter().all(|event| event.id != rewind_point.event_id));
8985

9086
session.disconnect().await.expect("disconnect session");
9187
client.stop().await.expect("stop client");
@@ -127,5 +123,4 @@ fn assert_same_path(expected: &Path, actual: &Path) {
127123
}
128124
}
129125

130-
static E2E: super::support::SharedE2eGroup =
131-
super::support::SharedE2eGroup::standard("rewind", 1);
126+
static E2E: super::support::SharedE2eGroup = super::support::SharedE2eGroup::standard("rewind", 1);

0 commit comments

Comments
 (0)