Paul Berry
c14fd57acc
Update AstBuilder to handle generic annotations.
...
Bug: https://github.com/dart-lang/sdk/issues/44838
Change-Id: If69cbbc13a087f0f6280da0bc7f9dbca1d3ec0ea
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/182740
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2021-02-05 20:57:18 +00:00
Sam Rawlins
cad324cf79
Analyzer: Extract all parser tests to individual files
...
Change-Id: Ia3f85355186e25d4cc38fcb15ed3770a1db5805c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/176360
Commit-Queue: Samuel Rawlins <srawlins@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-12-15 22:57:21 +00:00
Sam Rawlins
b8ce4baf7e
Remove 'checked mode' from checked_mode_compile_time_errors
...
Change-Id: I6576eb186149d540ce2dbc0e0aab7177ff4727be
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156484
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2020-07-31 19:20:58 +00:00
Sam Rawlins
d4f912dadb
Analyzer: Move all remaining tests from compile_time_error_code.dart and remove
...
Change-Id: Id3c2a3df6aea0437b9e0798040ac76fa96a01215
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/156080
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-07-29 02:51:50 +00:00
Konstantin Shcheglov
69526e6512
Depecate many AnalysisOptions fields.
...
Change-Id: Ibe219527d9abdad38bb99390d3023e7ee6bb8420
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/143251
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-04-15 18:36:52 +00:00
Paul Berry
5d4cd6d589
Breaking changes for analyzer version 0.39.
...
Change-Id: Ifa9ca24487f93f3eb0ec95eeb64f5bbb5aa32714
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113216
Commit-Queue: Paul Berry <paulberry@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2019-10-21 18:23:10 +00:00
Konstantin Shcheglov
9bf38afe9c
Check that ClassElement is Object using the corresponding getter.
...
Bug: https://github.com/dart-lang/sdk/issues/38589
Change-Id: I76c510bd212c48dbb3efc6b2ca2156d187937fa1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/119181
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2019-09-27 18:31:25 +00:00
Brian Wilkerson
233b4a71ca
Deprecate some unnecessarily duplicated error codes
...
Originally the spec made a distinction between when some of these
conditions were errors and when they were warnings. That distinction has
been removed, so this just cleans up our code to reflect that fact.
Change-Id: I3a6fdae2896eb93c6b9cacfea790cd9b553feec5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/115261
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-09-03 16:01:25 +00:00
Brian Wilkerson
de2ff7eebb
Split out the remaining HintCode tests
...
Change-Id: Ief95dda424d458d9ad1739df99c5533738559508
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/108620
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-07-10 14:58:14 +00:00
Konstantin Shcheglov
daa6ee6da9
Report NOT_ITERABLE_SPREAD and NOT_MAP_SPREAD.
...
R=brianwilkerson@google.com
Change-Id: I6668787b5b88d5125852e38bd9d30010e36c354b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97160
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2019-03-17 17:27:03 +00:00
Brian Wilkerson
4a7556840f
Rename tests ending with Test_Driver
...
Change-Id: I1b4822630a2508e8a41ba6c5564eae5a54f56622
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96740
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-03-13 13:38:22 +00:00
Paul Berry
a2eac98753
Merge HintCodeTest_Driver into HintCodeTest.
...
This is necessary because the internal code base considers a test file
to fail if it doesn't run any tests.
Alternative fixes considered:
- Put a dummy test in hint_code_test.dart
- Rename hint_code_test.dart to a name that doesn't end in _test.dart
Change-Id: I64fa2be7c76b4d2a85ee9b46ba1a1c21ae2903ae
Reviewed-on: https://dart-review.googlesource.com/c/94800
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2019-02-28 17:50:09 +00:00
Sam Rawlins
9450c6d829
Move SUBTYPE_OF_SEALED_CLASS to own file, and DriverResolutionTest
...
Change-Id: I1c5372bba522f1c3c818a2a1eafb366794e4700a
Reviewed-on: https://dart-review.googlesource.com/c/93929
Commit-Queue: Samuel Rawlins <srawlins@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2019-02-27 02:08:25 +00:00
Paul Berry
c9b1877cbf
Disable task model for clients by making WorkItem inconstructible.
...
The task model is still allowed in analyzer tests since we still have
some unit tests of non-task-model functionality that rely on the task
model to do their testing (see #35734 ).
Unit tests whose sole purpose was to test the task model have been
removed. Test files that now empty have been removed. Non-empty test
files that now contain no tests of their own have had their `main`
functions removed, and have been renamed so that the testing
infrastructure will no longer attempt to run them.
Change-Id: I8b4d0b2dde9337c4e1fe91e443a2c9da6eee8f4f
Reviewed-on: https://dart-review.googlesource.com/c/90720
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2019-01-24 16:29:17 +00:00
Brian Wilkerson
6c2ea4936a
Clean up several deprecation hints
...
Change-Id: I6191ddc4bb4a98c4976d8bc281b084bfd5073547
Reviewed-on: https://dart-review.googlesource.com/c/89941
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-01-17 01:05:24 +00:00
Konstantin Shcheglov
2beed40848
Move Workspace and its implementations into src/workspace.
...
R=brianwilkerson@google.com , paulberry@google.com
Change-Id: I172d95e55ced9925e8f428b9b07f432251ef5248
Reviewed-on: https://dart-review.googlesource.com/c/85462
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-11-27 21:50:00 +00:00
Brian Wilkerson
66a12140c7
Delete unused support for dealing with packages
...
Change-Id: I9cf325693703c04f2fbda143c7c666dc41af9e3d
Reviewed-on: https://dart-review.googlesource.com/c/82466
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Samuel Rawlins <srawlins@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2018-11-01 20:40:39 +00:00
Konstantin Shcheglov
9c585bf5df
Document that ResourceProvider requires absolute, normalized paths, and enforce this.
...
This allows us to avoid performing normalization, and work with paths
as is. So, this speeds up SourceFactoryImpl.restoreUri() from 7.5% to 3.7%
R=brianwilkerson@google.com
Change-Id: I085f3db40af6543fbb524a82fad48aa051e87937
Reviewed-on: https://dart-review.googlesource.com/77017
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2018-09-28 17:18:49 +00:00
Konstantin Shcheglov
1f52372bfa
Remove CFE integration from analyzer, analysis_server, and analyzer_cli.
...
AnalysisDriverResolutionTest is partially updated, about 30 failing
tests added. I will get back to it in a following CL, it is not
directly CFE integration, but updated understanding how we want to
resolve. For example we don't need types for non-expression identifiers.
Change-Id: I3daddbb6c66ffad7a726f3313a1199fd7387aa04
Reviewed-on: https://dart-review.googlesource.com/71883
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-08-29 13:46:45 +00:00
Kevin Millikin
f2eaf6aae7
Remove type parameters from the Fasta BodyBuilder
...
We are pivoting our implementation of FE/Analyzer integration a little
bit, and so the BodyBuilder will not be parameterized in exactly the
same way. Remove the existing parameterization from it and all the
supporting classes. This requires specializing the BodyBuilder to the
front end's instantiation of it and deleting the corresponding code in
the Analyzer.
Fixes https://github.com/dart-lang/sdk/issues/33503
Change-Id: I3ddcd2c5f5ebd8f2ff95f2ec8d4c7b98b70a0b0a
Reviewed-on: https://dart-review.googlesource.com/61502
Commit-Queue: Kevin Millikin <kmillikin@google.com >
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
Reviewed-by: Dan Rubel <danrubel@google.com >
2018-06-21 14:53:43 +00:00
danrubel
ebcf5bec30
Update Analyzer/CFE type resolution test to use AstBuildingForest
...
This updates the BodyBuilder to accept a Forest for either Kernel or Analyzer.
More work needs to be done to update the Forest type arguments specified in BodyBuilder.
Change-Id: I595535dc05572515a0b7cca5621de35146944ed3
Reviewed-on: https://dart-review.googlesource.com/54180
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Dan Rubel <danrubel@google.com >
2018-05-08 16:08:52 +00:00
Konstantin Shcheglov
9350925efe
Add InvalidCodeTest with end-to-end cases of problematic invalid code.
...
R=brianwilkerson@google.com , paulberry@google.com
Bug:
Change-Id: I39d26ea0b333ddfa69f281eeba78b04212e95a96
Reviewed-on: https://dart-review.googlesource.com/17960
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2017-11-01 18:16:25 +00:00
Konstantin Shcheglov
0549b3160e
Run hint tests with Kernel.
...
R=brianwilkerson@google.com
Bug:
Change-Id: Iea76082755b09015717c19c18a38ffe61072df02
Reviewed-on: https://dart-review.googlesource.com/10201
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2017-10-02 22:31:38 +00:00
Konstantin Shcheglov
f575c099b0
Run all *_driver tests also with Kernel. (attempt #2 )
...
With previous changes that fix finding dart:core on Windows and
flakyness of reporting import errors, I'd like to reland this CL.
Attempt #1 : https://dart-review.googlesource.com/c/sdk/+/7624
R=brianwilkerson@google.com , paulberry@google.com
Bug:
Change-Id: If5ab2c5ebe2204df6643ee42cbee5b49fb2d8c31
Reviewed-on: https://dart-review.googlesource.com/7961
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2017-09-24 18:27:27 +00:00
William Hesse
2274739c3c
Revert addition of kernel tests to analyzer unit tests
...
These tests have flaky failures on the buildbots and commit queue.
Revert "Run all *_driver tests also with Kernel."
This reverts commit d2f887e37b .
Revert "Adjusted status for analyzer/test/generated/strong_mode_kernel_test"
This reverts commit 055654e96d .
Revert "Made status for strong_mode_kernel_test broader (flaky)."
This reverts commit 824c3f56cc .
Bug:
Change-Id: I341762671efc31f168df2f5806653d9548bd43ae
Reviewed-on: https://dart-review.googlesource.com/7708
Reviewed-by: William Hesse <whesse@google.com >
2017-09-22 11:37:21 +00:00
Konstantin Shcheglov
d2f887e37b
Run all *_driver tests also with Kernel.
...
R=brianwilkerson@google.com , paulberry@google.com
Bug:
Change-Id: I92a0f5f2192c20276b166a9211ab1064bc6f2b82
Reviewed-on: https://dart-review.googlesource.com/7624
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2017-09-21 22:44:39 +00:00
Konstantin Shcheglov
50c964b819
Add option for AnalysisDriver to use KernelDriver and KernelResynthesizer.
...
Run NonErrorResolverTest_Driver tests with this option enabled.
We fail 163 out of 478 tests, or 35%.
R=brianwilkerson@google.com , paulberry@google.com
Bug:
Change-Id: Iac6154a14a1357fe239b0140f9f66de792825693
Reviewed-on: https://dart-review.googlesource.com/6340
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2017-09-18 02:09:14 +00:00
Brian Wilkerson
e454986288
Add code to run more tests from test_all
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2968233002 .
2017-07-06 12:24:01 -07:00
Dan Rubel
d566906167
cleanup unused incremental resolution
...
* remove unused analyzer incremental resolution
* remove unused Token.applyDelta method
Patch Set 1 is the original CL that was landed and reverted
https://codereview.chromium.org/2876993005
Patsh Set 2 contains additional fixes and test changes
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2884853002 .
2017-05-16 07:53:17 -04:00
Dan Rubel
d644be82ab
Revert "cleanup unused incremental resolution"
...
This reverts commit 77b383e6b8 .
Review-Url: https://codereview.chromium.org/2887443002 .
2017-05-15 11:01:57 -04:00
Dan Rubel
77b383e6b8
cleanup unused incremental resolution
...
* remove unused analyzer incremental resolution
* remove unused Token.applyDelta method
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2876993005 .
2017-05-15 09:09:25 -04:00
Devon Carew
3fd497b510
Ignore some uses of deprecated APIs.
...
BUG=
Review-Url: https://codereview.chromium.org/2796483002 .
2017-04-03 08:31:00 -07:00
Paul Berry
5c3ad68f13
Rename parser_test_fasta.dart to parser_fasta_test.dart.
...
Tests must be named "..._test.dart" in order to be run by the build
bots.
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2682753002 .
2017-02-07 11:12:49 -08:00
Paul Berry
62604294a2
Begin hooking up Fasta to analyzer parser tests.
...
R=ahe@google.com
Review-Url: https://codereview.chromium.org/2672403004 .
2017-02-07 05:45:58 -08:00
P.Y. Laligand
66cda63fea
Added support for GN workspaces.
...
BUG=
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2651613003 .
2017-01-25 09:26:45 -08:00
Paul Berry
c6206ea1de
Split "_Driver" tests to separate test files.
...
This avoids timeouts on my machine. Also it makes it easier to disable these tests when necessary.
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2627293002 .
2017-01-12 08:19:19 -08:00
Konstantin Shcheglov
799296e92b
Extract x_Driver tests that time out on Windows bots.
...
R=paulberry@google.com
BUG=
Review-Url: https://codereview.chromium.org/2623253003 .
2017-01-11 11:49:34 -08:00
Konstantin Shcheglov
5455fd0118
Remove 'initializeTestEnvironment' from 'analyzer'.
...
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/2399913002 .
2016-10-06 10:18:54 -07:00
Konstantin Shcheglov
175dad4f15
Switch 'analyzer' to 'package:test' and test_reflective_loader ^0.1.0.
...
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/2391423003 .
2016-10-06 08:46:35 -07:00
Konstantin Shcheglov
3f6afd8cf5
Add tests for resolveRelativeUri() and a workaround.
...
The actual problem should be fixed in SDKs Uri implementation.
https://github.com/dart-lang/sdk/issues/27447
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/2376073003 .
2016-09-28 13:20:26 -07:00
Konstantin Shcheglov
f658a7de42
Remove IncrementalScanner and IncrementalParser.
...
This code has never been used AFAIK.
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2330803002 .
2016-09-11 09:32:13 -07:00
Brian Wilkerson
9c5213a077
Generalize DartSdkManager to support embedder SDKs
...
R=pquitslund@google.com , scheglov@google.com
Review URL: https://codereview.chromium.org/2107793002 .
2016-06-28 13:48:57 -07:00
Jaime Wren
b7aff9c72f
Initial Bazel file resolver support.
...
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/2079873002 .
2016-06-17 14:20:55 -07:00
Konstantin Shcheglov
2e4f8a0601
Add missing test suites to the generated/test_all suite.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/1878413002 .
2016-04-12 13:18:18 -07:00
Konstantin Shcheglov
7ac77cfedf
Refine compound assignment type.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/1873913002 .
2016-04-08 12:19:23 -07:00
pq
75b1379a0f
Support for line-level error suppression ( #25685 ).
...
Adds filtering logic to apply source-level error suppression using a simple comment convention. For example, suppressing an invalid assignment would look like this:
```
//# ignore: invalid_assignment
int x = '';
```
Lists are supported as well:
```
//# ignore: invalid_assignment, const_initialized_with_non_constant_value
const String y = x;
```
Conversation on final format continues (https://github.com/dart-lang/sdk/issues/25685 ), so this can be treated as provisional but proves out the mechanics. Comments and concerns most welcome.
BUG=
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org/1702733002 .
2016-02-16 13:53:58 -08:00
Brian Wilkerson
dd0c42cb72
Moved the AST related tests to their new locations
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1612933006 .
2016-01-23 09:45:01 -08:00
Brian Slesinsky
771fea4502
move constant tests to constant_test.dart
...
BUG=
R=brianwilkerson@google.com , paulberry@google.com
Review URL: https://codereview.chromium.org/1616743006 .
2016-01-22 12:44:15 -08:00
Brian Wilkerson
66e07636f4
Moved the tests for the element model into locations corresponding to the implementation
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1529923003 .
2015-12-16 07:49:15 -08:00
Brian Wilkerson
f0d249e269
Clean up package imports and library names
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1513643009 .
2015-12-10 08:11:56 -08:00