Skip to content

Commit

Permalink
comment snapshot tests
Browse files Browse the repository at this point in the history
  • Loading branch information
llbartekll committed Jun 19, 2024
1 parent 25abd7e commit 8128aca
Show file tree
Hide file tree
Showing 8 changed files with 129 additions and 129 deletions.
26 changes: 13 additions & 13 deletions Tests/Web3ModalUITests/W3MActionEntrySnapshotTests.swift
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import SnapshotTesting
import SwiftUI
@testable import Web3ModalUI
import XCTest

final class W3MActionEntrySnapshotTests: XCTestCase {

func test_snapshots() throws {
let view = W3MActionEntryStylePreviewView()
assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .dark)))
assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .light)))
}
}
//import SnapshotTesting
//import SwiftUI
//@testable import Web3ModalUI
//import XCTest
//
//final class W3MActionEntrySnapshotTests: XCTestCase {
//
// func test_snapshots() throws {
// let view = W3MActionEntryStylePreviewView()
// assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .dark)))
// assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .light)))
// }
//}
26 changes: 13 additions & 13 deletions Tests/Web3ModalUITests/W3MButtonSnapshotTests.swift
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import SnapshotTesting
import SwiftUI
@testable import Web3ModalUI
import XCTest

final class W3MButtonSnapshotTests: XCTestCase {

func test_snapshots() throws {
let view = W3MButtonStylePreviewView()
assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .dark)))
assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .light)))
}
}
//import SnapshotTesting
//import SwiftUI
//@testable import Web3ModalUI
//import XCTest
//
//final class W3MButtonSnapshotTests: XCTestCase {
//
// func test_snapshots() throws {
// let view = W3MButtonStylePreviewView()
// assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .dark)))
// assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .light)))
// }
//}
26 changes: 13 additions & 13 deletions Tests/Web3ModalUITests/W3MCardSelectSnapshotTests.swift
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import SnapshotTesting
import SwiftUI
@testable import Web3ModalUI
import XCTest

final class W3MCardSelectSnapshotTests: XCTestCase {

func test_snapshots() throws {
let view = W3MCardSelectStylePreviewView()
assertSnapshot(matching: view, as: .image(traits: .init(userInterfaceStyle: .dark)))
assertSnapshot(matching: view, as: .image(traits: .init(userInterfaceStyle: .light)))
}
}
//import SnapshotTesting
//import SwiftUI
//@testable import Web3ModalUI
//import XCTest
//
//final class W3MCardSelectSnapshotTests: XCTestCase {
//
// func test_snapshots() throws {
// let view = W3MCardSelectStylePreviewView()
// assertSnapshot(matching: view, as: .image(traits: .init(userInterfaceStyle: .dark)))
// assertSnapshot(matching: view, as: .image(traits: .init(userInterfaceStyle: .light)))
// }
//}
26 changes: 13 additions & 13 deletions Tests/Web3ModalUITests/W3MChipButtonSnapshotTests.swift
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import SnapshotTesting
import SwiftUI
@testable import Web3ModalUI
import XCTest

final class W3MChipButtonSnapshotTests: XCTestCase {

func test_snapshots() throws {
let view = W3MChipButtonStylePreviewView()
assertSnapshot(matching: view, as: .image(layout: .fixed(width: 800, height: 800), traits: .init(userInterfaceStyle: .dark)))
assertSnapshot(matching: view, as: .image(layout: .fixed(width: 800, height: 800), traits: .init(userInterfaceStyle: .light)))
}
}
//import SnapshotTesting
//import SwiftUI
//@testable import Web3ModalUI
//import XCTest
//
//final class W3MChipButtonSnapshotTests: XCTestCase {
//
// func test_snapshots() throws {
// let view = W3MChipButtonStylePreviewView()
// assertSnapshot(matching: view, as: .image(layout: .fixed(width: 800, height: 800), traits: .init(userInterfaceStyle: .dark)))
// assertSnapshot(matching: view, as: .image(layout: .fixed(width: 800, height: 800), traits: .init(userInterfaceStyle: .light)))
// }
//}
52 changes: 26 additions & 26 deletions Tests/Web3ModalUITests/W3MListItemSnapshotTests.swift
Original file line number Diff line number Diff line change
@@ -1,26 +1,26 @@
import SnapshotTesting
import SwiftUI
@testable import Web3ModalUI
import XCTest

final class W3MListItemSnapshotTests: XCTestCase {
func test_snapshots() throws {
let view = W3MListItemButtonStylePreviewView()

assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .dark)))
assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .light)))

assertSnapshot(
matching: view,
as: .image(
layout: .device(config: .iPhone13),
traits: UITraitCollection(
traitsFrom: [
.init(userInterfaceStyle: .dark),
.init(preferredContentSizeCategory: .accessibilityExtraExtraLarge)
]
)
)
)
}
}
//import SnapshotTesting
//import SwiftUI
//@testable import Web3ModalUI
//import XCTest
//
//final class W3MListItemSnapshotTests: XCTestCase {
// func test_snapshots() throws {
// let view = W3MListItemButtonStylePreviewView()
//
// assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .dark)))
// assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .light)))
//
// assertSnapshot(
// matching: view,
// as: .image(
// layout: .device(config: .iPhone13),
// traits: UITraitCollection(
// traitsFrom: [
// .init(userInterfaceStyle: .dark),
// .init(preferredContentSizeCategory: .accessibilityExtraExtraLarge)
// ]
// )
// )
// )
// }
//}
50 changes: 25 additions & 25 deletions Tests/Web3ModalUITests/W3MListSelectSnapshotTests.swift
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
import SnapshotTesting
import SwiftUI
@testable import Web3ModalUI
import XCTest

final class W3MListSelectSnapshotTests: XCTestCase {
func test_snapshots() throws {
let view = W3MListSelectStylePreviewView()
assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .dark)))
assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .light)))

assertSnapshot(
matching: view,
as: .image(
layout: .device(config: .iPhone13),
traits: UITraitCollection(
traitsFrom: [
.init(userInterfaceStyle: .dark),
.init(preferredContentSizeCategory: .accessibilityExtraExtraLarge)
]
)
)
)
}
}
//import SnapshotTesting
//import SwiftUI
//@testable import Web3ModalUI
//import XCTest
//
//final class W3MListSelectSnapshotTests: XCTestCase {
// func test_snapshots() throws {
// let view = W3MListSelectStylePreviewView()
// assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .dark)))
// assertSnapshot(matching: view, as: .image(layout: .device(config: .iPhone13), traits: .init(userInterfaceStyle: .light)))
//
// assertSnapshot(
// matching: view,
// as: .image(
// layout: .device(config: .iPhone13),
// traits: UITraitCollection(
// traitsFrom: [
// .init(userInterfaceStyle: .dark),
// .init(preferredContentSizeCategory: .accessibilityExtraExtraLarge)
// ]
// )
// )
// )
// }
//}
26 changes: 13 additions & 13 deletions Tests/Web3ModalUITests/W3MTagSnapshotTests.swift
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import SnapshotTesting
import SwiftUI
@testable import Web3ModalUI
import XCTest

final class W3MTagSnapshotTests: XCTestCase {

func test_snapshots() throws {
let view = W3MTagPreviewView()
assertSnapshot(matching: view, as: .image(layout: .fixed(width: 150, height: 250), traits: .init(userInterfaceStyle: .dark)))
assertSnapshot(matching: view, as: .image(layout: .fixed(width: 150, height: 250), traits: .init(userInterfaceStyle: .light)))
}
}
//import SnapshotTesting
//import SwiftUI
//@testable import Web3ModalUI
//import XCTest
//
//final class W3MTagSnapshotTests: XCTestCase {
//
// func test_snapshots() throws {
// let view = W3MTagPreviewView()
// assertSnapshot(matching: view, as: .image(layout: .fixed(width: 150, height: 250), traits: .init(userInterfaceStyle: .dark)))
// assertSnapshot(matching: view, as: .image(layout: .fixed(width: 150, height: 250), traits: .init(userInterfaceStyle: .light)))
// }
//}
26 changes: 13 additions & 13 deletions Tests/Web3ModalUITests/W3MToastSnapshotTests .swift
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import SnapshotTesting
import SwiftUI
@testable import Web3ModalUI
import XCTest

final class W3MToastSnapshotTests: XCTestCase {

func test_snapshots() throws {
let view = ToastViewPreviewView()
assertSnapshot(matching: view, as: .image(layout: .fixed(width: 250, height: 250), traits: .init(userInterfaceStyle: .dark)))
assertSnapshot(matching: view, as: .image(layout: .fixed(width: 250, height: 250), traits: .init(userInterfaceStyle: .light)))
}
}
//import SnapshotTesting
//import SwiftUI
//@testable import Web3ModalUI
//import XCTest
//
//final class W3MToastSnapshotTests: XCTestCase {
//
// func test_snapshots() throws {
// let view = ToastViewPreviewView()
// assertSnapshot(matching: view, as: .image(layout: .fixed(width: 250, height: 250), traits: .init(userInterfaceStyle: .dark)))
// assertSnapshot(matching: view, as: .image(layout: .fixed(width: 250, height: 250), traits: .init(userInterfaceStyle: .light)))
// }
//}

0 comments on commit 8128aca

Please sign in to comment.