test: テストも修正

This commit is contained in:
usbharu 2024-09-22 11:43:19 +09:00
parent 309ea569e8
commit 96d51a885f
Signed by: usbharu
GPG Key ID: 95CBCF7046307B77
4 changed files with 8 additions and 8 deletions

View File

@ -22,7 +22,7 @@ import org.mockito.kotlin.doReturn
import org.mockito.kotlin.eq
import org.mockito.kotlin.whenever
import utils.TestTransaction
import java.net.URL
import java.net.URI
@ExtendWith(MockitoExtension::class)
class RegisterLocalActorApplicationServiceTest {
@ -51,7 +51,7 @@ class RegisterLocalActorApplicationServiceTest {
val transaction = TestTransaction
@Spy
val applicationConfig = ApplicationConfig(URL("http://example.com"))
val applicationConfig = ApplicationConfig(URI.create("http://example.com"))
@Spy
val idGenerateService = TwitterSnowflakeIdGenerateService

View File

@ -15,7 +15,7 @@ class RemoteActorCheckDomainServiceTest {
val remoteActor = RemoteActorCheckDomainService(
ApplicationConfig(
URI.create("https://local.example.com").toURL()
URI.create("https://local.example.com")
)
).isRemoteActor(
actor
@ -30,7 +30,7 @@ class RemoteActorCheckDomainServiceTest {
val localActor = RemoteActorCheckDomainService(
ApplicationConfig(
URI.create("https://local.example.com").toURL()
URI.create("https://local.example.com")
)
).isRemoteActor(
actor

View File

@ -15,7 +15,7 @@ import org.mockito.junit.jupiter.MockitoExtension
import org.mockito.kotlin.doReturn
import org.mockito.kotlin.eq
import org.mockito.kotlin.whenever
import java.net.URL
import java.net.URI
@ExtendWith(MockitoExtension::class)
class LocalActorDomainServiceImplTest {
@ -26,7 +26,7 @@ class LocalActorDomainServiceImplTest {
lateinit var actorRepository: ActorRepository
@Spy
val applicationConfig = ApplicationConfig(URL("http://example.com"))
val applicationConfig = ApplicationConfig(URI.create("http://example.com"))
@Test
fun findByNameAndDomainがnullならfalse() = runTest {

View File

@ -19,7 +19,7 @@ import org.mockito.junit.jupiter.MockitoExtension
import org.mockito.kotlin.*
import org.springframework.security.core.userdetails.UsernameNotFoundException
import utils.TestTransaction
import java.net.URL
import java.net.URI
import kotlin.test.assertEquals
@ExtendWith(MockitoExtension::class)
@ -34,7 +34,7 @@ class UserDetailsServiceImplTest {
lateinit var userDetailRepository: UserDetailRepository
@Spy
val applicationConfig = ApplicationConfig(URL("http://example.com"))
val applicationConfig = ApplicationConfig(URI.create("http://example.com"))
@Spy
val transaction = TestTransaction