Replace failing test with valid screen index test

- Remove test expecting validation error that doesn't exist
- Add test for screen-index parameter instead
This commit is contained in:
Peter Steinberger 2025-05-25 19:27:20 +02:00
parent 2940a9187d
commit 71bab246ac

View file

@ -83,12 +83,13 @@ final class ImageCommandTests: XCTestCase {
XCTAssertEqual(command.app, "Finder") XCTAssertEqual(command.app, "Finder")
} }
func testImageCommandValidationMissingWindowId() { func testImageCommandWithScreenIndex() throws {
// Test that window mode requires window ID // Test screen index parameter
XCTAssertThrowsError(try ImageCommand.parse([ let command = try ImageCommand.parse([
"--mode", "window" "--screen-index", "0"
// Missing --window-id parameter ])
]))
XCTAssertEqual(command.screenIndex, 0)
} }
func testImageCommandWithFocus() throws { func testImageCommandWithFocus() throws {