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
9c895fab
Commit
9c895fab
authored
Feb 27, 2018
by
Victor Choueiri
Committed by
Devon Carew
Feb 27, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add intelliJ path to doctor output (#14795)
parent
a5d3a9eb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
9 deletions
+15
-9
doctor.dart
packages/flutter_tools/lib/src/doctor.dart
+7
-6
doctor_test.dart
packages/flutter_tools/test/commands/doctor_test.dart
+8
-3
No files found.
packages/flutter_tools/lib/src/doctor.dart
View file @
9c895fab
...
...
@@ -276,7 +276,9 @@ class NoIdeValidator extends DoctorValidator {
}
abstract
class
IntelliJValidator
extends
DoctorValidator
{
IntelliJValidator
(
String
title
)
:
super
(
title
);
final
String
installPath
;
IntelliJValidator
(
String
title
,
this
.
installPath
)
:
super
(
title
);
String
get
version
;
String
get
pluginsPath
;
...
...
@@ -301,6 +303,8 @@ abstract class IntelliJValidator extends DoctorValidator {
Future
<
ValidationResult
>
validate
()
async
{
final
List
<
ValidationMessage
>
messages
=
<
ValidationMessage
>[];
messages
.
add
(
new
ValidationMessage
(
'IntelliJ at
$installPath
'
));
_validatePackage
(
messages
,
<
String
>[
'flutter-intellij'
,
'flutter-intellij.jar'
],
'Flutter'
,
minVersion:
kMinFlutterPluginVersion
);
_validatePackage
(
messages
,
<
String
>[
'Dart'
],
'Dart'
);
...
...
@@ -397,13 +401,11 @@ abstract class IntelliJValidator extends DoctorValidator {
}
class
IntelliJValidatorOnLinuxAndWindows
extends
IntelliJValidator
{
IntelliJValidatorOnLinuxAndWindows
(
String
title
,
this
.
version
,
this
.
installPath
,
this
.
pluginsPath
)
:
super
(
title
);
IntelliJValidatorOnLinuxAndWindows
(
String
title
,
this
.
version
,
String
installPath
,
this
.
pluginsPath
)
:
super
(
title
,
installPath
);
@override
String
version
;
final
String
installPath
;
@override
String
pluginsPath
;
...
...
@@ -451,10 +453,9 @@ class IntelliJValidatorOnLinuxAndWindows extends IntelliJValidator {
}
class
IntelliJValidatorOnMac
extends
IntelliJValidator
{
IntelliJValidatorOnMac
(
String
title
,
this
.
id
,
this
.
installPath
)
:
super
(
title
);
IntelliJValidatorOnMac
(
String
title
,
this
.
id
,
String
installPath
)
:
super
(
title
,
installPath
);
final
String
id
;
final
String
installPath
;
static
final
Map
<
String
,
String
>
_dirNameToId
=
<
String
,
String
>{
'IntelliJ IDEA.app'
:
'IntelliJIdea'
,
...
...
packages/flutter_tools/test/commands/doctor_test.dart
View file @
9c895fab
...
...
@@ -15,12 +15,17 @@ import '../src/context.dart';
void
main
(
)
{
group
(
'doctor'
,
()
{
testUsingContext
(
'intellij validator'
,
()
async
{
final
ValidationResult
result
=
await
new
IntelliJValidatorTestTarget
(
'Test'
).
validate
();
final
String
installPath
=
'/path/to/intelliJ'
;
final
ValidationResult
result
=
await
new
IntelliJValidatorTestTarget
(
'Test'
,
installPath
).
validate
();
expect
(
result
.
type
,
ValidationType
.
partial
);
expect
(
result
.
statusInfo
,
'version test.test.test'
);
expect
(
result
.
messages
,
hasLength
(
3
));
expect
(
result
.
messages
,
hasLength
(
4
));
ValidationMessage
message
=
result
.
messages
.
firstWhere
((
ValidationMessage
m
)
=>
m
.
message
.
startsWith
(
'IntelliJ '
));
expect
(
message
.
message
,
'IntelliJ at
$installPath
'
);
message
=
result
.
messages
.
firstWhere
((
ValidationMessage
m
)
=>
m
.
message
.
startsWith
(
'Dart '
));
expect
(
message
.
message
,
'Dart plugin version 162.2485'
);
...
...
@@ -148,7 +153,7 @@ void main() {
}
class
IntelliJValidatorTestTarget
extends
IntelliJValidator
{
IntelliJValidatorTestTarget
(
String
title
)
:
super
(
title
);
IntelliJValidatorTestTarget
(
String
title
,
String
installPath
)
:
super
(
title
,
installPath
);
@override
String
get
pluginsPath
=>
fs
.
path
.
join
(
'test'
,
'data'
,
'intellij'
,
'plugins'
);
...
...
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