Skip to content

Commit

Permalink
Remove empty use case for now
Browse files Browse the repository at this point in the history
  • Loading branch information
TWiStErRob committed Jan 13, 2024
1 parent 4f1ff74 commit fab3da5
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 32 deletions.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import io.micronaut.views.View
import net.twisterrob.blt.data.StaticData
import net.twisterrob.blt.io.feeds.trackernet.LineStatusFeed
import net.twisterrob.travel.domain.london.status.Feed
import net.twisterrob.travel.domain.london.status.api.HistoryUseCase
import net.twisterrob.travel.domain.london.status.api.HistoryRepository
import net.twisterrob.travel.domain.london.status.api.ParsedStatusItem
import net.twisterrob.travel.statushistory.viewmodel.LineColor
import net.twisterrob.travel.statushistory.viewmodel.Result
Expand All @@ -22,7 +22,7 @@ import java.util.Date

@Controller
class LineStatusHistoryController(
private val useCase: HistoryUseCase,
private val useCase: HistoryRepository,
private val staticData: StaticData,
) {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,9 @@ import net.twisterrob.blt.io.feeds.LocalhostUrlBuilder
import net.twisterrob.blt.io.feeds.TFLUrlBuilder
import net.twisterrob.blt.io.feeds.URLBuilder
import net.twisterrob.travel.domain.london.status.DomainHistoryRepository
import net.twisterrob.travel.domain.london.status.DomainHistoryUseCase
import net.twisterrob.travel.domain.london.status.DomainRefreshUseCase
import net.twisterrob.travel.domain.london.status.api.FeedParser
import net.twisterrob.travel.domain.london.status.api.HistoryUseCase
import net.twisterrob.travel.domain.london.status.api.HistoryRepository
import net.twisterrob.travel.domain.london.status.api.RefreshUseCase
import net.twisterrob.travel.domain.london.status.api.StatusDataSource
import net.twisterrob.travel.domain.london.status.api.StatusHistoryDataSource
Expand All @@ -38,8 +37,8 @@ class Dependencies {
statusHistoryDataSource: StatusHistoryDataSource,
statusDataSource: StatusDataSource,
feedParser: FeedParser,
): HistoryUseCase =
DomainHistoryUseCase(DomainHistoryRepository(statusHistoryDataSource, statusDataSource, feedParser))
): HistoryRepository =
DomainHistoryRepository(statusHistoryDataSource, statusDataSource, feedParser)

/**
* External dependency from domain layer in common KMP code.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import io.micronaut.test.extensions.junit5.annotation.MicronautTest
import jakarta.inject.Inject
import net.twisterrob.blt.data.StaticData
import net.twisterrob.blt.model.LineColors
import net.twisterrob.travel.domain.london.status.api.HistoryUseCase
import net.twisterrob.travel.domain.london.status.api.HistoryRepository
import org.hamcrest.MatcherAssert.assertThat
import org.hamcrest.Matchers.endsWith
import org.hamcrest.Matchers.startsWith
Expand All @@ -26,8 +26,8 @@ class LineStatusHistoryControllerIntegrationTest {
@Inject
lateinit var client: BlockingHttpClient

@MockBean(HistoryUseCase::class)
val historyUseCase: HistoryUseCase = mock()
@MockBean(HistoryRepository::class)
val historyUseCase: HistoryRepository = mock()

@MockBean(StaticData::class)
val staticData: StaticData = mock()
Expand Down

0 comments on commit fab3da5

Please sign in to comment.