Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(153)

Side by Side Diff: pkg/analyzer/test/src/dart/constant/value_test.dart

Issue 1842363004: More strong mode fixes for analyzer (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Backout options changes Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library analyzer.test.src.dart.constant.value_test; 5 library analyzer.test.src.dart.constant.value_test;
6 6
7 import 'package:analyzer/src/generated/constant.dart'; 7 import 'package:analyzer/src/generated/constant.dart';
8 import 'package:analyzer/src/generated/resolver.dart'; 8 import 'package:analyzer/src/generated/resolver.dart';
9 import 'package:analyzer/src/generated/testing/test_type_provider.dart'; 9 import 'package:analyzer/src/generated/testing/test_type_provider.dart';
10 import 'package:unittest/unittest.dart'; 10 import 'package:unittest/unittest.dart';
(...skipping 583 matching lines...) Expand 10 before | Expand all | Expand 10 after
594 594
595 void test_hasKnownValue_int_unknown() { 595 void test_hasKnownValue_int_unknown() {
596 expect(_intValue(null).hasKnownValue, isFalse); 596 expect(_intValue(null).hasKnownValue, isFalse);
597 } 597 }
598 598
599 void test_hasKnownValue_list_empty() { 599 void test_hasKnownValue_list_empty() {
600 expect(_listValue().hasKnownValue, isTrue); 600 expect(_listValue().hasKnownValue, isTrue);
601 } 601 }
602 602
603 void test_hasKnownValue_list_invalidElement() { 603 void test_hasKnownValue_list_invalidElement() {
604 expect(_listValue([_dynamicValue]).hasKnownValue, isTrue); 604 expect(_listValue([_dynamicValue()]).hasKnownValue, isTrue);
605 } 605 }
606 606
607 void test_hasKnownValue_list_valid() { 607 void test_hasKnownValue_list_valid() {
608 expect(_listValue([_intValue(23)]).hasKnownValue, isTrue); 608 expect(_listValue([_intValue(23)]).hasKnownValue, isTrue);
609 } 609 }
610 610
611 void test_hasKnownValue_map_empty() { 611 void test_hasKnownValue_map_empty() {
612 expect(_mapValue().hasKnownValue, isTrue); 612 expect(_mapValue().hasKnownValue, isTrue);
613 } 613 }
614 614
(...skipping 1405 matching lines...) Expand 10 before | Expand all | Expand 10 after
2020 } else { 2020 } else {
2021 return new DartObjectImpl( 2021 return new DartObjectImpl(
2022 _typeProvider.stringType, new StringState(value)); 2022 _typeProvider.stringType, new StringState(value));
2023 } 2023 }
2024 } 2024 }
2025 2025
2026 DartObjectImpl _symbolValue(String value) { 2026 DartObjectImpl _symbolValue(String value) {
2027 return new DartObjectImpl(_typeProvider.symbolType, new SymbolState(value)); 2027 return new DartObjectImpl(_typeProvider.symbolType, new SymbolState(value));
2028 } 2028 }
2029 } 2029 }
OLDNEW
« no previous file with comments | « pkg/analyzer/test/src/dart/ast/utilities_test.dart ('k') | pkg/analyzer/test/src/task/dart_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698