This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mqtt: | |
host: homeassistant.local | |
user: mqtt | |
password: "LsG6*XcUxWvaJcgL4ott" | |
go2rtc: | |
streams: | |
babyroom: | |
- rtsp://nestmtx:8554/babyroom | |
version: 0.14 | |
cameras: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
services: | |
frigate: | |
container_name: frigate | |
depends_on: | |
- nestmtx | |
restart: unless-stopped | |
image: ghcr.io/blakeblackshear/frigate:stable | |
shm_size: "64mb" | |
volumes: | |
- /etc/localtime:/etc/localtime:ro |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias: Afvalinzameling | |
description: "" | |
triggers: | |
- trigger: time | |
at: "20:00:00" | |
conditions: [] | |
actions: | |
- choose: | |
- conditions: | |
- condition: state |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.benchmark | |
import androidx.benchmark.junit4.BenchmarkRule | |
import androidx.benchmark.junit4.measureRepeated | |
import androidx.test.ext.junit.runners.AndroidJUnit4 | |
import dagger.internal.DoubleCheck | |
import dagger.internal.Provider | |
import org.junit.Rule | |
import org.junit.Test | |
import org.junit.runner.RunWith |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.benchmark | |
import androidx.benchmark.junit4.BenchmarkRule | |
import androidx.benchmark.junit4.measureRepeated | |
import androidx.test.ext.junit.runners.AndroidJUnit4 | |
import dagger.internal.DoubleCheck | |
import dagger.internal.Provider | |
import org.junit.Rule | |
import org.junit.Test | |
import org.junit.runner.RunWith |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.sxmp.clientsdk.network | |
import com.sxmp.clientsdk.common.ClientSdkInternalApi | |
import com.sxmp.coroutines.dispatchers | |
import com.sxmp.network.EndpointRequest | |
import com.sxmp.network.NetworkClient | |
import kotlinx.coroutines.withContext | |
import okhttp3.RequestBody | |
import okhttp3.Response |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class DaggerAppComponent implements AppComponent { | |
public class MyActivitySubcomponentImpl implements ActivitySubcomponent { | |
public void inject(MyActivity activity) {...} | |
public class OnboardingFragmentSubcomponentImpl implements OnboardingFragmentSubcomponent { | |
public void inject(OnboardingFragment fragment) { ... } | |
} | |
public class WelcomeFragmentSubcomponentImpl implements WelcomeFragmentSubcomponent { | |
public void inject(WelcomeFragment fragment) { ... } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@RunWith(AndroidJUnit4::class) | |
class MyFragmentTest { | |
@Test | |
fun buttonIsEnabled() { | |
TestMyFragment.testViewModel = MyViewModel().also | |
it.updateState(enabled = true) | |
} | |
launchFragmentInContainer<TestMyFragment>() | |
onView(withId(R.id.button)).check(matches(isEnabled())) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class TestMyFragment : MyFragment() { | |
override fun injectMembers() { | |
this.viewModel = testViewModel | |
} | |
companion object { | |
// static property can be set before launching the Fragment | |
// to a mock instance | |
lateinit var testViewModel: MyViewModel | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
override fun onAttach(context: Context) { | |
injectMembers() | |
super.onAttach(context) | |
} | |
protected open fun injectMembers() = | |
AndroidSupportInjection.inject(this) |
NewerOlder