Skip to content

Commit

Permalink
Sample project and CI update
Browse files Browse the repository at this point in the history
  • Loading branch information
tahirmt committed Feb 21, 2025
1 parent 422df7b commit 766fcd4
Show file tree
Hide file tree
Showing 14 changed files with 91 additions and 12 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,11 @@ on:
- synchronize

jobs:
verify-pods:
build:
runs-on: macos-latest

steps:
- uses: actions/checkout@v3
- run: xcodebuild test -scheme Nimble-SnapshotTesting -destination 'platform=iOS Simulator,OS=17.5,name=iPhone 15'
- uses: actions/checkout@v4
- run: sudo xcode-select -s /Applications/Xcode_16.2.0.app
- run: xcodebuild test -scheme Nimble-SnapshotTesting -destination 'platform=iOS Simulator,OS=18.2,name=iPhone 16 Pro'

2 changes: 2 additions & 0 deletions Example-SPM/Example-SPM.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
/* End PBXContainerItemProxy section */

/* Begin PBXFileReference section */
C82752002D68CE90001C8927 /* Example-SPM.xctestplan */ = {isa = PBXFileReference; lastKnownFileType = text; path = "Example-SPM.xctestplan"; sourceTree = "<group>"; };
C8C1592E27EC1DEF002296AF /* Example-SPM.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Example-SPM.app"; sourceTree = BUILT_PRODUCTS_DIR; };
C8C1593127EC1DEF002296AF /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
C8C1593327EC1DEF002296AF /* SceneDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SceneDelegate.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -84,6 +85,7 @@
C8C1592527EC1DEF002296AF = {
isa = PBXGroup;
children = (
C82752002D68CE90001C8927 /* Example-SPM.xctestplan */,
C8C1596127EC1E11002296AF /* Nimble-SnapshotTesting */,
C8C1593027EC1DEF002296AF /* Example-SPM */,
C8C1594727EC1DF0002296AF /* Example-SPMTests */,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,15 @@
"version": "1.5.0"
}
},
{
"package": "swift-custom-dump",
"repositoryURL": "https://github.com/pointfreeco/swift-custom-dump",
"state": {
"branch": null,
"revision": "82645ec760917961cfa08c9c0c7104a57a0fa4b1",
"version": "1.3.3"
}
},
{
"package": "swift-numerics",
"repositoryURL": "https://github.com/apple/swift-numerics.git",
Expand All @@ -69,17 +78,26 @@
"repositoryURL": "https://github.com/pointfreeco/swift-snapshot-testing.git",
"state": {
"branch": null,
"revision": "7b0bbbae90c41f848f90ac7b4df6c4f50068256d",
"version": "1.17.5"
"revision": "b2d4cb30735f4fbc3a01963a9c658336dd21e9ba",
"version": "1.18.1"
}
},
{
"package": "swift-syntax",
"repositoryURL": "https://github.com/swiftlang/swift-syntax",
"state": {
"branch": null,
"revision": "cb53fa1bd3219b0b23ded7dfdd3b2baff266fd25",
"version": "600.0.0"
"revision": "0687f71944021d616d34d922343dcef086855920",
"version": "600.0.1"
}
},
{
"package": "xctest-dynamic-overlay",
"repositoryURL": "https://github.com/pointfreeco/xctest-dynamic-overlay",
"state": {
"branch": null,
"revision": "b444594f79844b0d6d76d70fbfb3f7f71728f938",
"version": "1.5.1"
}
}
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,16 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
shouldUseLaunchSchemeArgsEnv = "YES">
<TestPlans>
<TestPlanReference
reference = "container:Example-SPM.xctestplan"
default = "YES">
</TestPlanReference>
</TestPlans>
<Testables>
<TestableReference
skipped = "NO">
skipped = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "C8C1594327EC1DF0002296AF"
Expand All @@ -41,7 +46,7 @@
</BuildableReference>
</TestableReference>
<TestableReference
skipped = "NO">
skipped = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "C8C1594D27EC1DF0002296AF"
Expand Down
51 changes: 51 additions & 0 deletions Example-SPM/Example-SPM.xctestplan
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{
"configurations" : [
{
"id" : "28191109-AD7F-4565-B5D7-2F2F91227910",
"name" : "Test Scheme Action",
"options" : {

}
}
],
"defaultOptions" : {
"environmentVariableEntries" : [
{
"key" : "SNAPSHOT_TESTING_RECORD",
"value" : "failed"
}
],
"targetForVariableExpansion" : {
"containerPath" : "container:Example-SPM.xcodeproj",
"identifier" : "C8C1592D27EC1DEF002296AF",
"name" : "Example-SPM"
},
"testExecutionOrdering" : "random"
},
"testTargets" : [
{
"target" : {
"containerPath" : "container:..",
"identifier" : "Nimble-SnapshotTestingTests",
"name" : "Nimble-SnapshotTestingTests"
}
},
{
"enabled" : false,
"target" : {
"containerPath" : "container:Example-SPM.xcodeproj",
"identifier" : "C8C1594327EC1DF0002296AF",
"name" : "Example-SPMTests"
}
},
{
"enabled" : false,
"target" : {
"containerPath" : "container:Example-SPM.xcodeproj",
"identifier" : "C8C1594D27EC1DF0002296AF",
"name" : "Example-SPMUITests"
}
}
],
"version" : 1
}
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// swift-tools-version:5.3
// swift-tools-version:5.9
import PackageDescription

let package = Package(
Expand Down
2 changes: 2 additions & 0 deletions Tests/Nimble-SnapshotTestingTests/SnapshotsSpec.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
// Created by Mahmood Tahir on 2024-09-14.
//

#if os(iOS)
import Foundation
import Nimble_SnapshotTesting
import Quick
Expand Down Expand Up @@ -97,3 +98,4 @@ private struct TestCodable: Codable {
let stringValue: String
let number: Int
}
#endif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 766fcd4

Please sign in to comment.