#include <gtk/gtk.h>
#include "flutter/shell/platform/linux/fl_binary_messenger_private.h"
#include "flutter/shell/platform/linux/fl_method_codec_private.h"
#include "flutter/shell/platform/linux/fl_platform_plugin.h"
#include "flutter/shell/platform/linux/public/flutter_linux/fl_json_method_codec.h"
#include "flutter/shell/platform/linux/public/flutter_linux/fl_method_codec.h"
#include "flutter/shell/platform/linux/testing/fl_test.h"
#include "flutter/shell/platform/linux/testing/mock_binary_messenger.h"
#include "flutter/testing/testing.h"
#include "gmock/gmock.h"
#include "gtest/gtest.h"
Go to the source code of this file.
Classes | |
class | MethodCallMatcher |
Functions | |
MATCHER_P (SuccessResponse, result, "") | |
static ::testing::Matcher< GBytes * > | MethodCall (const std::string &name, ::testing::Matcher< FlValue * > args) |
MATCHER_P (FlValueEq, value, "equal to "+::testing::PrintToString(value)) | |
G_DECLARE_FINAL_TYPE (FlTestApplication, fl_test_application, FL, TEST_APPLICATION, GtkApplication) struct _FlTestApplication | |
G_DEFINE_TYPE (FlTestApplication, fl_test_application, gtk_application_get_type()) static void fl_test_application_startup(GApplication *application) | |
static void | fl_test_application_activate (GApplication *application) |
static void | fl_test_application_dispose (GObject *object) |
static void | fl_test_application_class_init (FlTestApplicationClass *klass) |
static void | fl_test_application_init (FlTestApplication *self) |
FlTestApplication * | fl_test_application_new (gboolean *dispose_called) |
TEST (FlPlatformPluginTest, PlaySound) | |
TEST (FlPlatformPluginTest, ExitApplication) | |
TEST (FlPlatformPluginTest, ExitApplicationDispose) | |
|
static |
Definition at line 116 of file fl_platform_plugin_test.cc.
References args, fl_binary_messenger_send_response(), fl_json_method_codec_new(), fl_method_codec_encode_method_call(), fl_platform_plugin_new(), fl_value_new_map(), fl_value_new_string(), and fl_value_set_string_take().
Referenced by fl_test_application_class_init().
|
static |
Definition at line 149 of file fl_platform_plugin_test.cc.
References fl_test_application_activate(), and fl_test_application_dispose().
|
static |
Definition at line 141 of file fl_platform_plugin_test.cc.
Referenced by fl_test_application_class_init().
|
static |
Definition at line 155 of file fl_platform_plugin_test.cc.
FlTestApplication* fl_test_application_new | ( | gboolean * | dispose_called | ) |
G_DECLARE_FINAL_TYPE | ( | FlTestApplication | , |
fl_test_application | , | ||
FL | , | ||
TEST_APPLICATION | , | ||
GtkApplication | |||
) |
Definition at line 92 of file fl_platform_plugin_test.cc.
G_DEFINE_TYPE | ( | FlTestApplication | , |
fl_test_application | , | ||
gtk_application_get_type() | |||
) |
Definition at line 103 of file fl_platform_plugin_test.cc.
MATCHER_P | ( | FlValueEq | , |
value | , | ||
"equal to "+ | ::testing::PrintToStringvalue | ||
) |
Definition at line 88 of file fl_platform_plugin_test.cc.
References fl_value_equal(), and value.
MATCHER_P | ( | SuccessResponse | , |
result | , | ||
"" | |||
) |
Definition at line 19 of file fl_platform_plugin_test.cc.
References fl_json_method_codec_new(), fl_method_codec_decode_response(), fl_method_response_get_result(), fl_value_equal(), and result.
static ::testing::Matcher<GBytes*> MethodCall | ( | const std::string & | name, |
::testing::Matcher< FlValue * > | args | ||
) |
TEST | ( | FlPlatformPluginTest | , |
ExitApplication | |||
) |
Definition at line 193 of file fl_platform_plugin_test.cc.
References args, error, fl_binary_messenger_send_on_channel(), fl_binary_messenger_send_response(), fl_json_method_codec_new(), fl_method_codec_encode_method_call(), fl_platform_plugin_new(), fl_value_new_map(), fl_value_new_null(), fl_value_new_string(), fl_value_set_string_take(), MethodCall(), and TRUE.
TEST | ( | FlPlatformPluginTest | , |
ExitApplicationDispose | |||
) |
TEST | ( | FlPlatformPluginTest | , |
PlaySound | |||
) |
Definition at line 173 of file fl_platform_plugin_test.cc.
References args, fl_binary_messenger_send_response(), fl_json_method_codec_new(), fl_method_codec_encode_method_call(), fl_platform_plugin_new(), fl_value_new_null(), and fl_value_new_string().