diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 65a61408..7f2fe9ce 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,3 +30,7 @@ jobs: run: xcodebuild test -project Sample/Pluginized/TicTacToe/TicTacToe.xcodeproj -scheme ScoreSheetTests -destination 'platform=iOS Simulator,OS=16.1,name=iPhone 14' - name: "NeedleSamplePluginizedTicTacToeCoreTests" run: xcodebuild test -project Sample/Pluginized/TicTacToe/TicTacToe.xcodeproj -scheme TicTacToeCoreTests -destination 'platform=iOS Simulator,OS=16.1,name=iPhone 14' + - name: "NeedleSampleSwiftUIMVVMApp" + run: xcodebuild build -project Sample/SwiftUI-MVVM/TicTacToe/TicTacToe.xcodeproj -scheme TicTacToe -destination 'platform=iOS Simulator,OS=16.1,name=iPhone 14' + - name: "NeedleSampleSwiftUIMVVMTests" + run: xcodebuild test -project Sample/SwiftUI-MVVM/TicTacToe/TicTacToe.xcodeproj -scheme TicTacToeTests -destination 'platform=iOS Simulator,OS=16.1,name=iPhone 14' diff --git a/Sample/SwiftUI-MVVM/TicTacToe/Sources/LoggedIn/LoggedInComponent.swift b/Sample/SwiftUI-MVVM/TicTacToe/Sources/LoggedIn/LoggedInComponent.swift index 513efe05..3062d740 100644 --- a/Sample/SwiftUI-MVVM/TicTacToe/Sources/LoggedIn/LoggedInComponent.swift +++ b/Sample/SwiftUI-MVVM/TicTacToe/Sources/LoggedIn/LoggedInComponent.swift @@ -19,7 +19,7 @@ import SwiftUI class LoggedInComponent: Component, LoggedInBuilder { - var scoreStream: ScoreStream { + public var scoreStream: ScoreStream { return mutableScoreStream } diff --git a/Sample/SwiftUI-MVVM/TicTacToe/Sources/NeedleGenerated.swift b/Sample/SwiftUI-MVVM/TicTacToe/Sources/NeedleGenerated.swift index 34ea7652..e2e1ed01 100644 --- a/Sample/SwiftUI-MVVM/TicTacToe/Sources/NeedleGenerated.swift +++ b/Sample/SwiftUI-MVVM/TicTacToe/Sources/NeedleGenerated.swift @@ -104,13 +104,14 @@ extension LoggedOutComponent: Registration { extension LoggedInComponent: Registration { public func registerItems() { - + localTable["scoreStream-ScoreStream"] = { [unowned self] in self.scoreStream as Any } } } extension RootComponent: Registration { public func registerItems() { - + localTable["playersStream-PlayersStream"] = { [unowned self] in self.playersStream as Any } + localTable["mutablePlayersStream-MutablePlayersStream"] = { [unowned self] in self.mutablePlayersStream as Any } } } diff --git a/Sample/SwiftUI-MVVM/TicTacToe/Sources/Root/RootComponent.swift b/Sample/SwiftUI-MVVM/TicTacToe/Sources/Root/RootComponent.swift index cde1ee8f..301471ee 100644 --- a/Sample/SwiftUI-MVVM/TicTacToe/Sources/Root/RootComponent.swift +++ b/Sample/SwiftUI-MVVM/TicTacToe/Sources/Root/RootComponent.swift @@ -19,11 +19,11 @@ import SwiftUI class RootComponent: BootstrapComponent { - var playersStream: PlayersStream { + public var playersStream: PlayersStream { return mutablePlayersStream } - var mutablePlayersStream: MutablePlayersStream { + public var mutablePlayersStream: MutablePlayersStream { return shared { PlayersStreamImpl() } }