CursorInputMapper: migrate remaining tests

Change I0f0307dc57edcc62d0ce24b15bf0d9e8b8b915c6 left a few tests using
the old InputMapperTest (instead of the new InputMapperUnitTest),
because they needed a fake InputDeviceContext creating (or looked like
they needed it; some turned out to be simpler to migrate). This change
moves them over.

Bug: 283812079
Test: atest inputflinger_tests
Change-Id: I18c82c7823f0739b62dba06f4e550069b3d0130e
diff --git a/services/inputflinger/reader/include/InputDevice.h b/services/inputflinger/reader/include/InputDevice.h
index 31dcb2e..cbd719c 100644
--- a/services/inputflinger/reader/include/InputDevice.h
+++ b/services/inputflinger/reader/include/InputDevice.h
@@ -280,7 +280,7 @@
 class InputDeviceContext {
 public:
     InputDeviceContext(InputDevice& device, int32_t eventHubId);
-    ~InputDeviceContext();
+    virtual ~InputDeviceContext();
 
     inline InputReaderContext* getContext() { return mContext; }
     inline int32_t getId() { return mDeviceId; }
@@ -450,7 +450,7 @@
     inline std::optional<std::string> getDeviceTypeAssociation() const {
         return mDevice.getDeviceTypeAssociation();
     }
-    inline std::optional<DisplayViewport> getAssociatedViewport() const {
+    virtual std::optional<DisplayViewport> getAssociatedViewport() const {
         return mDevice.getAssociatedViewport();
     }
     [[nodiscard]] inline std::list<NotifyArgs> cancelTouch(nsecs_t when, nsecs_t readTime) {