Flutter Engine
Loading...
Searching...
No Matches
method_call_unittests.cc
Go to the documentation of this file.
1
// Copyright 2013 The Flutter Authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#include "
flutter/shell/platform/common/client_wrapper/include/flutter/method_call.h
"
6
7
#include <memory>
8
#include <string>
9
10
#include "gtest/gtest.h"
11
12
namespace
flutter
{
13
14
TEST
(MethodCallTest, Basic) {
15
const
std::string method_name(
"method_name"
);
16
const
int
argument = 42;
17
MethodCall<int>
method_call
(method_name, std::make_unique<int>(argument));
18
EXPECT_EQ(
method_call
.method_name(), method_name);
19
ASSERT_NE(
method_call
.arguments(),
nullptr
);
20
EXPECT_EQ(*
method_call
.arguments(), 42);
21
}
22
23
}
// namespace flutter
flutter::MethodCall
Definition
method_call.h:18
method_call
G_BEGIN_DECLS G_MODULE_EXPORT FlMethodCall * method_call
Definition
fl_method_channel.h:120
method_call.h
flutter
Definition
asset_manager.cc:10
flutter::TEST
TEST(FrameTimingsRecorderTest, RecordVsync)
Definition
frame_timings_recorder_unittests.cc:22
shell
platform
common
client_wrapper
method_call_unittests.cc
Generated on Wed Nov 5 2025 21:33:15 for Flutter Engine by
1.9.8