InputMapper refactor: Modify InputMapper constructor for configuration
We are refactoring Input-mapper(s) to ensure they are configured at the
time of initialisation.
In this CL we are changing InputMapper's constructor to accept the
reader configuration to facilitate initialisation.
Test: build, inputflinger_tests, presubmit checks
Bug: 256009910
Change-Id: I710b892f51268a001d076f387163ac3274f5b0d1
diff --git a/services/inputflinger/tests/fuzzers/SwitchInputFuzzer.cpp b/services/inputflinger/tests/fuzzers/SwitchInputFuzzer.cpp
index c4938f2..590207e 100644
--- a/services/inputflinger/tests/fuzzers/SwitchInputFuzzer.cpp
+++ b/services/inputflinger/tests/fuzzers/SwitchInputFuzzer.cpp
@@ -24,8 +24,8 @@
std::make_shared<ThreadSafeFuzzedDataProvider>(data, size);
FuzzContainer fuzzer(fdp);
- SwitchInputMapper& mapper = fuzzer.getMapper<SwitchInputMapper>();
auto policyConfig = fuzzer.getPolicyConfig();
+ SwitchInputMapper& mapper = fuzzer.getMapper<SwitchInputMapper>(policyConfig);
// Loop through mapper operations until randomness is exhausted.
while (fdp->remaining_bytes() > 0) {