Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
0a93f4eb
Unverified
Commit
0a93f4eb
authored
Oct 16, 2019
by
Emmanuel Garcia
Committed by
GitHub
Oct 16, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove isNewAndroidEmbeddingEnabled flag when reading an existing pro… (#42684)
parent
1dc09e4c
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
25 additions
and
20 deletions
+25
-20
pubspec.yaml
dev/integration_tests/release_smoke_test/pubspec.yaml
+2
-2
hello_world_test.dart
...sts/release_smoke_test/test_adapter/hello_world_test.dart
+2
-2
platform_plugins.dart
packages/flutter_tools/lib/src/platform_plugins.dart
+0
-4
plugins.dart
packages/flutter_tools/lib/src/plugins.dart
+0
-3
cocoapods_test.dart
...lutter_tools/test/general.shard/macos/cocoapods_test.dart
+1
-1
plugins_test.dart
packages/flutter_tools/test/general.shard/plugins_test.dart
+14
-7
project_test.dart
packages/flutter_tools/test/general.shard/project_test.dart
+6
-1
No files found.
dev/integration_tests/release_smoke_test/pubspec.yaml
View file @
0a93f4eb
...
...
@@ -17,7 +17,7 @@ dev_dependencies:
flutter_test
:
sdk
:
flutter
instrumentation_adapter
:
0.1.3
e2e
:
0.2.1
archive
:
2.0.10
# THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade"
args
:
1.5.2
# THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade"
...
...
@@ -40,4 +40,4 @@ dev_dependencies:
test_api
:
0.2.5
# THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade"
xml
:
3.5.0
# THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade"
# PUBSPEC CHECKSUM:
8361
# PUBSPEC CHECKSUM:
669f
dev/integration_tests/release_smoke_test/test_adapter/hello_world_test.dart
View file @
0a93f4eb
...
...
@@ -4,10 +4,10 @@
import
'package:flutter_test/flutter_test.dart'
;
import
'package:release_smoke_test/main.dart'
as
smoke
;
import
'package:
instrumentation_adapter/instrumentation_adapter
.dart'
;
import
'package:
e2e/e2e
.dart'
;
void
main
(
)
{
InstrumentationAdapter
FlutterBinding
.
ensureInitialized
();
E2EWidgets
FlutterBinding
.
ensureInitialized
();
testWidgets
(
'Hello world smoke test'
,
(
WidgetTester
tester
)
async
{
smoke
.
main
();
// builds the app and schedules a frame but doesn't trigger one
...
...
packages/flutter_tools/lib/src/platform_plugins.dart
View file @
0a93f4eb
...
...
@@ -7,7 +7,6 @@ import 'package:yaml/yaml.dart';
import
'base/common.dart'
;
import
'base/file_system.dart'
;
import
'features.dart'
;
/// Marker interface for all platform specific plugin config impls.
abstract
class
PluginPlatform
{
...
...
@@ -75,9 +74,6 @@ class AndroidPlugin extends PluginPlatform {
String
get
_embeddingVersion
=>
_cachedEmbeddingVersion
??=
_getEmbeddingVersion
();
String
_getEmbeddingVersion
()
{
if
(!
featureFlags
.
isNewAndroidEmbeddingEnabled
)
{
return
'1'
;
}
assert
(
pluginPath
!=
null
);
final
String
baseMainPath
=
fs
.
path
.
join
(
pluginPath
,
...
...
packages/flutter_tools/lib/src/plugins.dart
View file @
0a93f4eb
...
...
@@ -360,9 +360,6 @@ List<Map<String, dynamic>> _extractPlatformMaps(List<Plugin> plugins, String typ
/// Returns the version of the Android embedding that the current
/// [project] is using.
String
_getAndroidEmbeddingVersion
(
FlutterProject
project
)
{
if
(!
featureFlags
.
isNewAndroidEmbeddingEnabled
)
{
return
'1'
;
}
assert
(
project
.
android
!=
null
);
final
File
androidManifest
=
project
.
android
.
appManifestFile
;
assert
(
androidManifest
.
existsSync
());
...
...
packages/flutter_tools/test/general.shard/macos/cocoapods_test.dart
View file @
0a93f4eb
...
...
@@ -273,7 +273,7 @@ void main() {
..
writeAsStringSync
(
'Existing release config'
);
final
FlutterProject
project
=
FlutterProject
.
fromPath
(
'project'
);
await
injectPlugins
(
project
);
await
injectPlugins
(
project
,
checkProjects:
true
);
final
String
debugContents
=
projectUnderTest
.
ios
.
xcodeConfigFor
(
'Debug'
).
readAsStringSync
();
expect
(
debugContents
,
contains
(
...
...
packages/flutter_tools/test/general.shard/plugins_test.dart
View file @
0a93f4eb
...
...
@@ -148,7 +148,13 @@ flutter:
testUsingContext
(
'Registrant uses old embedding in app project'
,
()
async
{
when
(
flutterProject
.
isModule
).
thenReturn
(
false
);
when
(
featureFlags
.
isNewAndroidEmbeddingEnabled
).
thenReturn
(
false
);
final
File
androidManifest
=
flutterProject
.
directory
.
childDirectory
(
'android'
)
.
childFile
(
'AndroidManifest.xml'
)
..
createSync
(
recursive:
true
)
..
writeAsStringSync
(
kAndroidManifestUsingOldEmbedding
);
when
(
androidProject
.
appManifestFile
).
thenReturn
(
androidManifest
);
await
injectPlugins
(
flutterProject
);
...
...
@@ -167,7 +173,6 @@ flutter:
testUsingContext
(
'Registrant uses new embedding if app uses new embedding'
,
()
async
{
when
(
flutterProject
.
isModule
).
thenReturn
(
false
);
when
(
featureFlags
.
isNewAndroidEmbeddingEnabled
).
thenReturn
(
true
);
final
File
androidManifest
=
flutterProject
.
directory
.
childDirectory
(
'android'
)
...
...
@@ -193,7 +198,6 @@ flutter:
testUsingContext
(
'Registrant uses shim for plugins using old embedding if app uses new embedding'
,
()
async
{
when
(
flutterProject
.
isModule
).
thenReturn
(
false
);
when
(
featureFlags
.
isNewAndroidEmbeddingEnabled
).
thenReturn
(
true
);
final
File
androidManifest
=
flutterProject
.
directory
.
childDirectory
(
'android'
)
...
...
@@ -291,7 +295,6 @@ plugin3:${pluginUsingOldEmbeddingDir.childDirectory('lib').uri.toString()}
testUsingContext
(
'Registrant doesn
\'
t use new embedding if app doesn
\'
t use new embedding'
,
()
async
{
when
(
flutterProject
.
isModule
).
thenReturn
(
false
);
when
(
featureFlags
.
isNewAndroidEmbeddingEnabled
).
thenReturn
(
true
);
final
File
androidManifest
=
flutterProject
.
directory
.
childDirectory
(
'android'
)
...
...
@@ -317,7 +320,13 @@ plugin3:${pluginUsingOldEmbeddingDir.childDirectory('lib').uri.toString()}
testUsingContext
(
'Registrant uses old embedding in module project'
,
()
async
{
when
(
flutterProject
.
isModule
).
thenReturn
(
true
);
when
(
featureFlags
.
isNewAndroidEmbeddingEnabled
).
thenReturn
(
false
);
final
File
androidManifest
=
flutterProject
.
directory
.
childDirectory
(
'android'
)
.
childFile
(
'AndroidManifest.xml'
)
..
createSync
(
recursive:
true
)
..
writeAsStringSync
(
kAndroidManifestUsingOldEmbedding
);
when
(
androidProject
.
appManifestFile
).
thenReturn
(
androidManifest
);
await
injectPlugins
(
flutterProject
);
...
...
@@ -336,7 +345,6 @@ plugin3:${pluginUsingOldEmbeddingDir.childDirectory('lib').uri.toString()}
testUsingContext
(
'Registrant uses new embedding if module uses new embedding'
,
()
async
{
when
(
flutterProject
.
isModule
).
thenReturn
(
true
);
when
(
featureFlags
.
isNewAndroidEmbeddingEnabled
).
thenReturn
(
true
);
final
File
androidManifest
=
flutterProject
.
directory
.
childDirectory
(
'android'
)
...
...
@@ -362,7 +370,6 @@ plugin3:${pluginUsingOldEmbeddingDir.childDirectory('lib').uri.toString()}
testUsingContext
(
'Registrant doesn
\'
t use new embedding if module doesn
\'
t use new embedding'
,
()
async
{
when
(
flutterProject
.
isModule
).
thenReturn
(
true
);
when
(
featureFlags
.
isNewAndroidEmbeddingEnabled
).
thenReturn
(
true
);
final
File
androidManifest
=
flutterProject
.
directory
.
childDirectory
(
'android'
)
...
...
packages/flutter_tools/test/general.shard/project_test.dart
View file @
0a93f4eb
...
...
@@ -531,7 +531,12 @@ Future<FlutterProject> someProject() async {
final
Directory
directory
=
fs
.
directory
(
'some_project'
);
directory
.
childFile
(
'.packages'
).
createSync
(
recursive:
true
);
directory
.
childDirectory
(
'ios'
).
createSync
(
recursive:
true
);
directory
.
childDirectory
(
'android'
).
createSync
(
recursive:
true
);
final
Directory
androidDirectory
=
directory
.
childDirectory
(
'android'
)
..
createSync
(
recursive:
true
);
androidDirectory
.
childFile
(
'AndroidManifest.xml'
)
.
writeAsStringSync
(
'<manifest></manifest>'
);
return
FlutterProject
.
fromDirectory
(
directory
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment