https://kotlinlang.org
Join Slack
hey! Is there any way when using ```awaitAll()``` with different variables of different types for it...
x

xii

over 3 years ago
hey! Is there any way when using
awaitAll()
with different variables of different types for it to not be casted as Any?
👍 1
x
j
+2
  • 4
  • 20
  • 304
Is there a good pattern anyone uses to test mocking both successful and error responses from a serve...
b

bbaldino

over 3 years ago
Is there a good pattern anyone uses to test mocking both successful and error responses from a server when testing a client? So you’d normally have something like:
val mockHttpClient = HttpClient(MockEngine) {
    engine {
        addHandler { request -> {
            when (request.url.encodedPath) {
                "url1" -> respond(someSuccessResponse)
            }
        }
    }
}
val client = MyClient(mockHttpClient)
...
but I want to be able to test how
MyClient
handles different kinds of responses when hitting
url1
, but the mock engine config is fixed…is there a good way to be able to change it to simulate different responses?
b
a
  • 2
  • 3
  • 304
Hi, in my `resources` folder I have a folder named `languages` with inside a `kotlin.json` file, but...
a

Ayfri

about 4 years ago
Hi, in my
resources
folder I have a folder named
languages
with inside a
kotlin.json
file, but when I do
""::class.java.getResource("languages/kotlin.json")
I get
null
, why does it occurs ?
âś… 1
a
t
e
  • 3
  • 4
  • 304
Is there a compose equivalent to `android:keepScreenOn`?
a

André Kindwall

over 4 years ago
Is there a compose equivalent to
android:keepScreenOn
?
a
k
+2
  • 4
  • 8
  • 304
I have a `pointerInput` modifier on `Box` and `pointerInteropFilter` on its children. However, the `...
s

Se7eN

over 4 years ago
I have a
pointerInput
modifier on
Box
and
pointerInteropFilter
on its children. However, the
pointerInteropFilter
modifiers on the children do not receive events because of the
pointerInput
on the parent. When I remove the parent
pointerInput
, the
pointerInteropFilter
modifiers on children work fine. I'm creating a draggable, rotatable, and resizable composable with controls at the corner (see image). How can I fix this? Code in thread
s
a
  • 2
  • 5
  • 304
The testing setup in <https://github.com/demiurg906/kotlin-compiler-plugin-template> seems to be out...
y

Youssef Shoaib [MOD]

7 months ago
The testing setup in https://github.com/demiurg906/kotlin-compiler-plugin-template seems to be out of date with 2.2.0. Is there an updated version somewhere?
y
d
  • 2
  • 6
  • 303
Hey guys, I just tried out the “K2 Kotlin Mode” in Koala Beta 2 but it’s stuck at “Analyzing…” for e...
s

svenjacobs

over 1 year ago
Hey guys, I just tried out the “K2 Kotlin Mode” in Koala Beta 2 but it’s stuck at “Analyzing…” for every Kotlin file and there is no syntax highlighting. AGP is at version
8.5.0-beta02
. Anyone else with the same problem?
âž• 1
s
c
+2
  • 4
  • 19
  • 303
Does KMP support swift package manager on ios side?
n

New

over 1 year ago
Does KMP support swift package manager on ios side?
n
j
j
  • 3
  • 5
  • 303
Hello ppl. Is there anyway to get transactions to rollback for tests in kotest + spring without usin...
i

Ido Flax

over 3 years ago
Hello ppl. Is there anyway to get transactions to rollback for tests in kotest + spring without using annotationSpec?
i
l
t
  • 3
  • 15
  • 303
I would like to take a screenshot in desktop app as a part of jvmTest. In androidTest I can do that...
m

Michal Harakal

over 4 years ago
I would like to take a screenshot in desktop app as a part of jvmTest. In androidTest I can do that with takeScreenshot method from uiautomator.UiDevice. Any hint how I can do that without spinning up an Android emulator (I have both targets …)?
m
b
i
  • 3
  • 4
  • 303
Previous232233234Next

kotlinlang

A modern programming language that makes developers happier.

Powered by