Skip to content

Commit 011856f

Browse files
committed
fixes
Signed-off-by: Sertac Ozercan <sozercan@gmail.com>
1 parent 869501e commit 011856f

13 files changed

+149
-13
lines changed

App/KasetApp.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,6 @@ struct KasetApp: App {
123123
.environment(self.authService)
124124
}
125125
.commands {
126-
127126
// Playback commands
128127
CommandMenu("Playback") {
129128
// Play/Pause - Space

Tests/KasetTests/ExploreViewModelTests.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ final class ExploreViewModelTests: XCTestCase {
2424

2525
func testLoadSuccess() async {
2626
// Given
27+
// Note: "Charts" section is filtered out by ExploreViewModel since it's in the sidebar
2728
let expectedSections = [
2829
TestFixtures.makeHomeSection(title: "New releases"),
2930
TestFixtures.makeHomeSection(title: "Charts"),
@@ -37,8 +38,10 @@ final class ExploreViewModelTests: XCTestCase {
3738
// Then
3839
XCTAssertTrue(self.mockClient.getExploreCalled)
3940
XCTAssertEqual(self.viewModel.loadingState, .loaded)
40-
XCTAssertEqual(self.viewModel.sections.count, 3)
41+
// "Charts" section is filtered out, so we expect 2 sections
42+
XCTAssertEqual(self.viewModel.sections.count, 2)
4143
XCTAssertEqual(self.viewModel.sections[0].title, "New releases")
44+
XCTAssertEqual(self.viewModel.sections[1].title, "Moods & genres")
4245
}
4346

4447
func testLoadError() async {

Tests/KasetUITests/AppLaunchUITests.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import XCTest
22

33
/// UI tests that verify the app launches correctly.
4+
@MainActor
45
final class AppLaunchUITests: KasetUITestCase {
56
// MARK: - App Launch
67

Tests/KasetUITests/ExploreViewUITests.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import XCTest
22

33
/// UI tests for the ExploreView.
4+
@MainActor
45
final class ExploreViewUITests: KasetUITestCase {
56
// MARK: - Basic Display
67

Tests/KasetUITests/HomeViewUITests.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import XCTest
22

33
/// UI tests for the HomeView.
4+
@MainActor
45
final class HomeViewUITests: KasetUITestCase {
56
// MARK: - Basic Display
67

Tests/KasetUITests/KasetUITestCase.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ enum TestAccessibilityID {
2323

2424
/// Base class for Kaset UI tests.
2525
/// Provides common setup, launch configuration, and helper methods.
26+
@MainActor
2627
class KasetUITestCase: XCTestCase {
2728
/// The application under test.
2829
var app: XCUIApplication!

Tests/KasetUITests/LibraryViewUITests.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import XCTest
22

33
/// UI tests for the LibraryView (Playlists).
4+
@MainActor
45
final class LibraryViewUITests: KasetUITestCase {
56
// MARK: - Basic Display
67

Tests/KasetUITests/LikedMusicViewUITests.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import XCTest
22

33
/// UI tests for the LikedMusicView.
4+
@MainActor
45
final class LikedMusicViewUITests: KasetUITestCase {
56
// MARK: - Basic Display
67

Tests/KasetUITests/PlayerBarUITests.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import XCTest
22

33
/// UI tests for the PlayerBar.
4+
@MainActor
45
final class PlayerBarUITests: KasetUITestCase {
56
// MARK: - Player Bar Visibility
67

Tests/KasetUITests/SearchViewUITests.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import XCTest
22

33
/// UI tests for the SearchView.
4+
@MainActor
45
final class SearchViewUITests: KasetUITestCase {
56
// MARK: - Search Field
67

0 commit comments

Comments
 (0)