1 /*
2 * Copyright (C) 2023 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17 package com.android.systemui.bouncer.domain.interactor
18
19 import android.content.applicationContext
20 import com.android.keyguard.keyguardSecurityModel
21 import com.android.keyguard.keyguardUpdateMonitor
22 import com.android.systemui.bouncer.data.repository.keyguardBouncerRepository
23 import com.android.systemui.bouncer.ui.BouncerView
24 import com.android.systemui.classifier.falsingCollector
25 import com.android.systemui.concurrency.fakeExecutor
26 import com.android.systemui.deviceentry.domain.interactor.deviceEntryFaceAuthInteractor
27 import com.android.systemui.keyguard.DismissCallbackRegistry
28 import com.android.systemui.keyguard.data.repository.trustRepository
29 import com.android.systemui.kosmos.Kosmos
30 import com.android.systemui.kosmos.applicationCoroutineScope
31 import com.android.systemui.statusbar.policy.KeyguardStateControllerImpl
32 import com.android.systemui.user.domain.interactor.selectedUserInteractor
33 import com.android.systemui.util.concurrency.mockExecutorHandler
34 import com.android.systemui.util.mockito.mock
35
<lambda>null36 var Kosmos.mockPrimaryBouncerInteractor by Kosmos.Fixture { mock<PrimaryBouncerInteractor>() }
37
38 val Kosmos.primaryBouncerInteractor by
<lambda>null39 Kosmos.Fixture {
40 PrimaryBouncerInteractor(
41 repository = keyguardBouncerRepository,
42 primaryBouncerView = mock<BouncerView>(),
43 mainHandler = mockExecutorHandler(executor = fakeExecutor),
44 keyguardStateController = mock<KeyguardStateControllerImpl>(),
45 keyguardSecurityModel = keyguardSecurityModel,
46 primaryBouncerCallbackInteractor = mock<PrimaryBouncerCallbackInteractor>(),
47 falsingCollector = falsingCollector,
48 dismissCallbackRegistry = mock<DismissCallbackRegistry>(),
49 context = applicationContext,
50 keyguardUpdateMonitor = keyguardUpdateMonitor,
51 trustRepository = trustRepository,
52 applicationScope = applicationCoroutineScope,
53 selectedUserInteractor = selectedUserInteractor,
54 deviceEntryFaceAuthInteractor = deviceEntryFaceAuthInteractor,
55 )
56 }
57