Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
sxychenjing
engine
提交
0622b051
E
engine
项目概览
sxychenjing
/
engine
与 Fork 源项目一致
从无法访问的项目Fork
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
E
engine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
0622b051
编写于
10月 09, 2019
作者:
D
Dan Field
提交者:
GitHub
10月 09, 2019
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Minimal test harness for iOS (#13029)
上级
ed1557f8
变更
6
显示空白变更内容
内联
并排
Showing
6 changed file
with
99 addition
and
0 deletion
+99
-0
build/darwin/ios_app.gni
build/darwin/ios_app.gni
+20
-0
ci/licenses_golden/licenses_flutter
ci/licenses_golden/licenses_flutter
+2
-0
shell/platform/darwin/ios/BUILD.gn
shell/platform/darwin/ios/BUILD.gn
+26
-0
shell/platform/darwin/ios/FlutterTestsInfo.plist
shell/platform/darwin/ios/FlutterTestsInfo.plist
+20
-0
shell/platform/darwin/ios/flutter_unittests.mm
shell/platform/darwin/ios/flutter_unittests.mm
+19
-0
testing/run_all_unittests.cc
testing/run_all_unittests.cc
+12
-0
未找到文件。
build/darwin/ios_app.gni
0 → 100644
浏览文件 @
0622b051
# Copyright 2013 The Flutter Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
template("ios_app") {
assert(is_ios)
copy("${target_name}__info_plist") {
sources = [ invoker.info_plist ]
outputs = [ "$root_out_dir/${target_name}.app/Info.plist" ]
}
executable("$target_name") {
forward_variables_from(invoker, "*")
output_name = "${target_name}.app/$target_name"
deps += [
":${target_name}__info_plist",
]
}
}
ci/licenses_golden/licenses_flutter
浏览文件 @
0622b051
...
...
@@ -731,6 +731,8 @@ FILE: ../../../flutter/shell/platform/darwin/common/framework/Source/FlutterStan
FILE: ../../../flutter/shell/platform/darwin/common/framework/Source/FlutterStandardCodec_Internal.h
FILE: ../../../flutter/shell/platform/darwin/common/framework/Source/flutter_codecs_unittest.mm
FILE: ../../../flutter/shell/platform/darwin/common/framework/Source/flutter_standard_codec_unittest.mm
FILE: ../../../flutter/shell/platform/darwin/ios/FlutterTestsInfo.plist
FILE: ../../../flutter/shell/platform/darwin/ios/flutter_unittests.mm
FILE: ../../../flutter/shell/platform/darwin/ios/framework/Flutter.podspec
FILE: ../../../flutter/shell/platform/darwin/ios/framework/Headers/Flutter.h
FILE: ../../../flutter/shell/platform/darwin/ios/framework/Headers/FlutterAppDelegate.h
...
...
shell/platform/darwin/ios/BUILD.gn
浏览文件 @
0622b051
...
...
@@ -5,9 +5,11 @@
assert(is_ios)
import("//build/config/ios/ios_sdk.gni")
import("$flutter_root/build/darwin/ios_app.gni")
import("$flutter_root/common/config.gni")
import("$flutter_root/shell/gpu/gpu.gni")
import("$flutter_root/shell/platform/darwin/common/framework_shared.gni")
import("$flutter_root/testing/testing.gni")
_flutter_framework_dir = "$root_out_dir/Flutter.framework"
...
...
@@ -248,6 +250,30 @@ shared_library("copy_and_verify_framework_headers") {
]
}
test_fixtures("flutter_tests_fixtures") {
fixtures = []
}
ios_app("FlutterTests") {
testonly = true
info_plist = "FlutterTestsInfo.plist"
sources = [
"flutter_unittests.mm",
]
libs = [
"Foundation.framework",
]
deps = [
":flutter_tests_fixtures",
"//flutter/runtime:libdart",
"//flutter/testing",
]
}
group("flutter_framework") {
deps = [
":copy_and_verify_framework_headers",
...
...
shell/platform/darwin/ios/FlutterTestsInfo.plist
0 → 100644
浏览文件 @
0622b051
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist
version=
"1.0"
>
<dict>
<key>
CFBundleDevelopmentRegion
</key>
<string>
en
</string>
<key>
CFBundleExecutable
</key>
<string>
FlutterTests
</string>
<key>
CFBundleIdentifier
</key>
<string>
io.flutter.FlutterTests
</string>
<key>
CFBundleInfoDictionaryVersion
</key>
<string>
6.0
</string>
<key>
CFBundleName
</key>
<string>
FlutterTests
</string>
<key>
CFBundleVersion
</key>
<string>
1.0
</string>
<key>
CFBundleShortVersionString
</key>
<string>
1.0
</string>
</dict>
</plist>
shell/platform/darwin/ios/flutter_unittests.mm
0 → 100644
浏览文件 @
0622b051
// Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#import <Foundation/Foundation.h>
#include "flutter/testing/testing.h"
namespace
flutter_tests
{
TEST
(
SmokeTest
,
Success
)
{
EXPECT_EQ
(
1
,
1
);
}
TEST
(
SmokeTest
,
Fail
)
{
EXPECT_EQ
(
1
,
2
);
}
}
testing/run_all_unittests.cc
浏览文件 @
0622b051
...
...
@@ -2,9 +2,21 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "flutter/fml/build_config.h"
#include "gtest/gtest.h"
#ifdef OS_IOS
#include <asl.h>
#endif // OS_IOS
int
main
(
int
argc
,
char
**
argv
)
{
#ifdef OS_IOS
asl_log_descriptor
(
NULL
,
NULL
,
ASL_LEVEL_NOTICE
,
STDOUT_FILENO
,
ASL_LOG_DESCRIPTOR_WRITE
);
asl_log_descriptor
(
NULL
,
NULL
,
ASL_LEVEL_ERR
,
STDERR_FILENO
,
ASL_LOG_DESCRIPTOR_WRITE
);
#endif // OS_IOS
::
testing
::
InitGoogleTest
(
&
argc
,
argv
);
return
RUN_ALL_TESTS
();
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录