simpleperf: fix test on APCT.

Bug: http://b/77470883
Test: run adb shell
Test: /data/local/tmp/simpleperf_unit_test/simpleperf_unit_test.
Change-Id: I640ad76b68842045f6ecdcb3cf686b7823d7d5db
(cherry picked from commit 03a31c13168f6502883e8beb4dbc76bc064a54a0)
diff --git a/simpleperf/cmd_record_test.cpp b/simpleperf/cmd_record_test.cpp
index 7f20886..31f1727 100644
--- a/simpleperf/cmd_record_test.cpp
+++ b/simpleperf/cmd_record_test.cpp
@@ -270,7 +270,10 @@
   ASSERT_TRUE(RunRecordCmd({"-t", tid_list}));
 }
 
-TEST(record_cmd, no_monitored_threads) { ASSERT_FALSE(RecordCmd()->Run({""})); }
+TEST(record_cmd, no_monitored_threads) {
+  TemporaryFile tmpfile;
+  ASSERT_FALSE(RecordCmd()->Run({"-o", tmpfile.path}));
+}
 
 TEST(record_cmd, more_than_one_event_types) {
   ASSERT_TRUE(RunRecordCmd({"-e", "cpu-cycles,cpu-clock"}));