Skip to content
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
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ test-macos:
-scheme MarkdownUI \
-destination platform="macOS"

test-macos-maccatalyst:
xcodebuild test \
-scheme MarkdownUI \
-destination platform="macOS,variant=Mac Catalyst"

test-ios:
xcodebuild test \
-scheme MarkdownUI \
Expand All @@ -18,7 +23,7 @@ test-watchos:
-scheme MarkdownUI \
-destination platform="watchOS Simulator,name=Apple Watch SE (40mm) (2nd generation)"

test: test-macos test-ios test-tvos test-watchos
test: test-macos test-macos-maccatalyst test-ios test-tvos test-watchos

format:
swift format --in-place --recursive .
Expand Down
1 change: 1 addition & 0 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ let package = Package(
.macOS(.v12),
.iOS(.v15),
.tvOS(.v15),
.macCatalyst(.v15),
.watchOS(.v8),
],
products: [
Expand Down
4 changes: 4 additions & 0 deletions Tests/MarkdownUITests/MarkdownImageTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
final class MarkdownImageTests: XCTestCase {
private let layout = SwiftUISnapshotLayout.device(config: .iPhone8)

override func setUpWithError() throws {
try XCTSkipIf(UIDevice.current.userInterfaceIdiom == .pad, "Skipping on Mac Catalyst")
}

func testFailingImage() {
let view = Markdown {
#"""
Expand Down
4 changes: 4 additions & 0 deletions Tests/MarkdownUITests/MarkdownListTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
final class MarkdownListTests: XCTestCase {
private let layout = SwiftUISnapshotLayout.device(config: .iPhone8)

override func setUpWithError() throws {
try XCTSkipIf(UIDevice.current.userInterfaceIdiom == .pad, "Skipping on Mac Catalyst")
}

func testTaskList() {
let view = Markdown {
#"""
Expand Down
4 changes: 4 additions & 0 deletions Tests/MarkdownUITests/MarkdownTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
final class MarkdownTests: XCTestCase {
private let layout = SwiftUISnapshotLayout.device(config: .iPhone8)

override func setUpWithError() throws {
try XCTSkipIf(UIDevice.current.userInterfaceIdiom == .pad, "Skipping on Mac Catalyst")
}

func testBlockquote() {
let view = Markdown {
#"""
Expand Down
4 changes: 4 additions & 0 deletions Tests/MarkdownUITests/ThemeDocCTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
final class ThemeDocCTests: XCTestCase {
private let layout = SwiftUISnapshotLayout.device(config: .iPhone8)

override func setUpWithError() throws {
try XCTSkipIf(UIDevice.current.userInterfaceIdiom == .pad, "Skipping on Mac Catalyst")
}

func testInlines() {
let view = ThemePreview(theme: .docC) {
#"""
Expand Down
4 changes: 4 additions & 0 deletions Tests/MarkdownUITests/ThemeGitHubTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
private let layout = SwiftUISnapshotLayout.device(config: .iPhone8)
private let perceptualPrecision: Float = 0.97

override func setUpWithError() throws {
try XCTSkipIf(UIDevice.current.userInterfaceIdiom == .pad, "Skipping on Mac Catalyst")
}

func testInlines() {
let view = ThemePreview(theme: .gitHub) {
#"""
Expand Down