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
130a5cb6
Commit
130a5cb6
authored
Sep 20, 2015
by
Adam Barth
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix analyzer warnings
We were just missing a few type casts in tests to make the analyzer happy.
parent
27e6381e
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
5 deletions
+5
-5
transitions.dart
packages/flutter/lib/src/widgets/transitions.dart
+0
-1
mock_services.dart
packages/unit/test/services/mock_services.dart
+1
-1
input_test.dart
packages/unit/test/widget/input_test.dart
+4
-3
No files found.
packages/flutter/lib/src/widgets/transitions.dart
View file @
130a5cb6
...
...
@@ -3,7 +3,6 @@
// found in the LICENSE file.
import
'package:sky/animation.dart'
;
import
'package:sky/src/widgets/animated_component.dart'
;
import
'package:sky/src/widgets/basic.dart'
;
import
'package:sky/src/widgets/framework.dart'
;
import
'package:sky/src/widgets/global_key_watcher.dart'
;
...
...
packages/unit/test/services/mock_services.dart
View file @
130a5cb6
...
...
@@ -10,7 +10,7 @@ class _ServiceMocker {
// Map of interface names to mock implementations.
Map
<
String
,
Object
>
_interfaceMock
=
new
Map
<
String
,
Object
>();
bool
_requestService
(
String
url
,
Object
proxy
)
{
bool
_requestService
(
String
url
,
dynamic
proxy
)
{
Object
mock
=
_interfaceMock
[
proxy
.
impl
.
name
];
if
(
mock
!=
null
)
{
// Replace the proxy's implementation of the service interface with the
...
...
packages/unit/test/widget/input_test.dart
View file @
130a5cb6
import
'package:mojo_services/keyboard/keyboard.mojom.dart'
;
import
'package:sky/rendering.dart'
;
import
'package:sky/services.dart'
;
import
'package:sky/widgets.dart'
;
import
'package:test/test.dart'
;
...
...
@@ -9,7 +10,7 @@ import '../services/mock_services.dart';
class
MockKeyboard
implements
KeyboardService
{
KeyboardClient
client
;
void
show
(
Object
client
,
int
type
)
{
void
show
(
KeyboardClientStub
client
,
int
type
)
{
this
.
client
=
client
.
impl
;
}
...
...
@@ -41,7 +42,7 @@ void main() {
tester
.
pumpFrame
(
builder
);
Input
input
=
tester
.
findWidget
((
Widget
widget
)
=>
widget
.
key
==
inputKey
);
Size
emptyInputSize
=
input
.
renderObject
.
size
;
Size
emptyInputSize
=
(
input
.
renderObject
as
RenderBox
)
.
size
;
// Simulate entry of text through the keyboard.
expect
(
mockKeyboard
.
client
,
isNotNull
);
...
...
@@ -54,6 +55,6 @@ void main() {
tester
.
pumpFrame
(
builder
);
// Check that the Input with text has the same size as the empty Input.
expect
(
input
.
renderObject
.
size
,
equals
(
emptyInputSize
));
expect
(
(
input
.
renderObject
as
RenderBox
)
.
size
,
equals
(
emptyInputSize
));
});
}
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