Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Enum naming convention #129

Merged
merged 4 commits into from
Nov 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Sources/WebDriver/Requests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,7 @@ public enum Requests {
public var xOffset: Int
public var yOffset: Int

private enum CodableKeys: String, CodingKey {
private enum CodingKeys: String, CodingKey {
case element = "element"
case xOffset = "xoffset"
case yOffset = "yoffset"
Expand Down
8 changes: 8 additions & 0 deletions Tests/UnitTests/APIToRequestMappingTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,14 @@ class APIToRequestMappingTests: XCTestCase {
XCTAssert(try element.enabled == true)
}

func testSessionTouchScroll() throws {
let mockWebDriver: MockWebDriver = MockWebDriver()
let session = Session(webDriver: mockWebDriver, existingId: "mySession")
let element = Element(session: session, id: "myElement")
mockWebDriver.expect(path: "session/mySession/touch/scroll", method: .post)
try session.touchScroll(element: element, xOffset: 9, yOffset: 16)
}
compnerd marked this conversation as resolved.
Show resolved Hide resolved

func testWindow() throws {
let mockWebDriver: MockWebDriver = MockWebDriver()
let session = Session(webDriver: mockWebDriver, existingId: "mySession")
Expand Down