Skip to content

Commit 90be965

Browse files
committed
chore(api): bump swift-figma-api to 0.2.0, use FigmaClient.baseURL in mock
Update dependency to 0.2.0 which exposes baseURL as a public static property. Replace hardcoded URL string in MockClient with the canonical FigmaClient.baseURL for single source of truth.
1 parent ff3bafc commit 90be965

3 files changed

Lines changed: 5 additions & 6 deletions

File tree

Package.resolved

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ let package = Package(
2727
.package(url: "https://github.com/mattt/swift-yyjson", from: "0.5.0"),
2828
.package(url: "https://github.com/apple/pkl-swift", from: "0.8.0"),
2929
.package(url: "https://github.com/DesignPipe/swift-svgkit.git", from: "0.1.0"),
30-
.package(url: "https://github.com/DesignPipe/swift-figma-api.git", from: "0.1.0"),
30+
.package(url: "https://github.com/DesignPipe/swift-figma-api.git", from: "0.2.0"),
3131
],
3232
targets: [
3333
// Main target

Tests/ExFigTests/Helpers/MockClient.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,7 @@ public final class MockClient: Client, @unchecked Sendable {
5757

5858
public func request<T: Endpoint>(_ endpoint: T) async throws -> T.Content {
5959
let key = String(describing: type(of: endpoint))
60-
// swiftlint:disable:next force_unwrapping
61-
let baseURL = URL(string: "https://api.figma.com/v1/")!
60+
let baseURL = FigmaClient.baseURL
6261
let request = try endpoint.makeRequest(baseURL: baseURL)
6362

6463
// Record timestamp and get delay (thread-safe)

0 commit comments

Comments
 (0)