Commit Graph

149 Commits

Author SHA1 Message Date
Devon Carew f08ada2d52 Disable a flakey analysis server test.
Change-Id: I9af9145305e29a37c82afc0b2199fba7866a0e0d
Reviewed-on: https://dart-review.googlesource.com/65281
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2018-07-17 14:54:07 +00:00
Devon Carew 6f648307b9 Address two flaky tests.
Change-Id: Ia32cd45d03e45d8a5bbc76cc37343f3e23c3a138
Reviewed-on: https://dart-review.googlesource.com/64581
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2018-07-11 16:39:43 +00:00
Devon Carew 3cc0a9a230 Another fix for a race in a test.
Change-Id: I548dff1e4abb45b7d8516923db92dc9d315d72d2
Reviewed-on: https://dart-review.googlesource.com/64220
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2018-07-09 21:29:45 +00:00
Devon Carew 2519892295 Address a race condition in a test.
Change-Id: I86c06ee42ece8b24d37c1b4bb47861614756de82
Reviewed-on: https://dart-review.googlesource.com/64083
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-07-09 16:53:16 +00:00
Konstantin Shcheglov f385664e4b Store unresolved assignments as UnresolvedVariableAssignmentJudgment.
R=brianwilkerson@google.com, paulberry@google.com

Change-Id: I4738ba450b1f7e7cab794bdc34a88996d1d827b3
Reviewed-on: https://dart-review.googlesource.com/63360
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-07-02 17:14:28 +00:00
Devon Carew 17b53a2835 Test out no_implicit_casts on the analyzer source base.
Change-Id: I4eb2414d7d9bbe21883c9e5e8eca10f2eaafb465
Reviewed-on: https://dart-review.googlesource.com/62725
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2018-06-28 02:20:43 +00:00
Konstantin Shcheglov a1efbd326f Change FrontEndCompiler.getOutline() to return full kernels.
So, we still get annotations, default values, and initializers.

See also https://github.com/dart-lang/sdk/issues/33633 that
tracks the fact that we now perform body resolution twice.

R=brianwilkerson@google.com, paulberry@google.com

Change-Id: Idbe628411512c24f73ff3ac4773c895a75cd0b28
Reviewed-on: https://dart-review.googlesource.com/62400
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-06-26 19:56:40 +00:00
Devon Carew f381778867 Update the status of analysis server tests.
Change-Id: I12c2366209ae712e064888714dd65ce8ec9d89f7
Reviewed-on: https://dart-review.googlesource.com/62003
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2018-06-23 18:42:31 +00:00
Devon Carew e132240c91 Re-enable some failing analyzer_cli --use-cfe tests.
Change-Id: I1085c0dd5d8e4fa818bf82b258a3639a1d196266
Reviewed-on: https://dart-review.googlesource.com/61903
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
2018-06-23 01:17:05 +00:00
Devon Carew 02721709c3 Fix a committed solo test and mark it as passing now.
Change-Id: Id0185d229ef84ac78bba1906ce90ad0083c9651d
Reviewed-on: https://dart-review.googlesource.com/61905
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2018-06-22 16:17:55 +00:00
Konstantin Shcheglov 4ebdb31646 Separate getOutline() and getResolution() in FrontEndCompiler.
This will allow us later switch from applying resolution to parsed
AST to directly generating resolved AST, when we get to this.

New failing tests are because of absence of annotations, constant
values (initializers, default values), and constructor initializers
in outlines.

We also don't get errors for constant value computing, hence some
tests are now passing, but not by the reason we intended to test.

R=brianwilkerson@google.com, paulberry@google.com

Change-Id: I5b45da592563af02c45e8cda160ccd24487c3591
Reviewed-on: https://dart-review.googlesource.com/61743
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
2018-06-22 04:04:33 +00:00
Paul Berry 06a588233c Fix package_root_test.dart on mac buildbot.
I broke this in 591cf85c76, but failed
to notice because the test is disabled on Linux (see
https://github.com/dart-lang/sdk/issues/33382)

Change-Id: Ida2bc1ec03db83bdb9c5cbd58cf4534d95fe7781
Reviewed-on: https://dart-review.googlesource.com/61307
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2018-06-20 20:54:47 +00:00
Paul Berry 591cf85c76 Re-enable the old analyzer/FE integration logic.
This gets the tests running again.  I'll follow this up with CLs that
reshape the ResolutionStorer API to match the Factory API we're
building, and then after that we can transition the code over to
calling the Factory API directly.

Fixes #33504
Fixes #32258

Change-Id: I105841ed5b2ed1198ec5e3e7387f694c61d36ca7
Reviewed-on: https://dart-review.googlesource.com/61101
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2018-06-20 14:35:31 +00:00
Devon Carew fe3bba8b03 Switch integration tests to use a snapshot for the analysis server.
Bug: https://github.com/dart-lang/sdk/issues/33189
Change-Id: I27ac08545c36c1cc1c7718b945f298b6286731b9
Reviewed-on: https://dart-review.googlesource.com/57300
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2018-05-30 17:29:55 +00:00
Paul Berry b4e176b570 Adjust timeout for reanalyze_concurrent_test.dart.
Change-Id: Ic1cb4aa69cfeec14109b9503db140f85fcfab06b
Reviewed-on: https://dart-review.googlesource.com/48445
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-03-26 20:20:52 +00:00
Brian Wilkerson 9df1d66b57 Flip analyzer and server to preview-dart-2 by default
Change-Id: I5d009debf962ba49ae715a87aa117538f552fbdb
Reviewed-on: https://dart-review.googlesource.com/47122
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-03-19 20:57:17 +00:00
Konstantin Shcheglov e1909cb52a Update Outline protocol - change offset/length, add codeOffset/codeLength.
R=brianwilkerson@google.com

Change-Id: I4b5c03a21254f7c497adc4c043641b18599c5c39
Reviewed-on: https://dart-review.googlesource.com/45764
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-03-09 01:52:57 +00:00
Danny Tuppeny f91ab5b64e Fix test failures on Windows
Windows doesn't have curl, but PowerShell does have Invoke-WebRequest (aliased to curl).
Also Fix set_general_subscriptions_test path issue.

Bug: https://github.com/dart-lang/sdk/issues/32355
Change-Id: I7567e2e01fc2158443b86569894ab0b17b3c5096
Reviewed-on: https://dart-review.googlesource.com/44240
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Danny Tuppeny <danny@tuppeny.com>
2018-03-01 07:46:36 +00:00
Kevin Millikin be30b62e3d Remove the Kernel type inference listener
We have decided to move to a different API for Fasta/Analyzer
integration, one that doesn't involve compiling to Kernel or observing
type inference.  The listener API will become broken, so let's just
remove it before that happens.

We lose the ability to trace type inference so let's restore that
ability next.  The analyzer's resolution storer is not used, but that
code has been left.  The resolution applier will no longer work
without the resolution storer, so those tests have been disabled.

Change-Id: If9ac5aba2d5de7788d8a65f7fa8410599e636d21
Reviewed-on: https://dart-review.googlesource.com/42400
Commit-Queue: Kevin Millikin <kmillikin@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-02-21 16:28:07 +00:00
Jaime Wren cd878bc433 Create the new flag --use-cfe in the analyzer, analysis server and analyzer_cli and migrate the old behavior of --preview-dart-2 to --use-cfe. The --preview-dart-2 flag is now a no-op, with functionality coming soon.
See https://github.com/dart-lang/sdk/issues/31640

Change-Id: I2db2e7ef6a324cbd5d369b807e331495fed167df
Reviewed-on: https://dart-review.googlesource.com/33121
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Jaime Wren <jwren@google.com>
2018-01-08 22:37:05 +00:00
Paul Berry 105b170ddb Roll package test to 0.12.29+1 and stack_trace to 1.9.0
This required some changes to analysis_server, since analysis_server
used to have its own version of pumpEventQueue().  Since
pumpEventQueue() is now provided by the test package, I've removed
analysis_server's version, and I've updated some of the call sites to
pass in "times: 5000" to replicate the old analysis_server behavior.

This also required some changes to analyzer, since the fail() method
is now marked as @alwaysThrows, so no code may follow it without
producing a dead code hint.

Change-Id: Ie5ef3a5cc685c18da02de699e59f63f3bb8865f7
Reviewed-on: https://dart-review.googlesource.com/32683
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2018-01-07 14:22:23 +00:00
Devon Carew 0a289c8341 Add analysis server analysis domain preview dart 2 tests.
Bug:
Change-Id: Id1ea8cbd214ec5f117c83f7df31b53456254ff78
Reviewed-on: https://dart-review.googlesource.com/28802
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2017-12-12 21:43:29 +00:00
Devon Carew 98f716a8b2 Disable the manage imports on paste feature.
Bug: https://github.com/dart-lang/sdk/issues/31456
Change-Id: I4045c4a72a0ad3fe66c019cce2499b79c4c2086d
Reviewed-on: https://dart-review.googlesource.com/23960
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Kevin Moore <kevmoo@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2017-11-27 20:23:11 +00:00
Devon Carew ee1404e91a Allow analysis server benchmarks to run with --preview-dart-2.
Bug:
Change-Id: Ifb9a5c596d3ad63012177cfb4e0bd7b107e78aff
Reviewed-on: https://dart-review.googlesource.com/20941
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2017-11-15 07:37:51 +00:00
Brian Wilkerson 35f6d5da1b Correctly handle adding imports when pasting into part files
R=devoncarew@google.com

Review-Url: https://codereview.chromium.org/3001733002 .
2017-08-16 07:43:36 -07:00
Brian Wilkerson ae69313731 Initial implementation of the import-aware copy support
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2988183002 .
2017-08-01 08:32:12 -07:00
Konstantin Shcheglov 00d5012906 Format analyzer, analysis_server, analyzer_plugin, front_end and kernel with the latest dartfmt.
...instead of mixing formatting with actual changes in many CLs.

R=ahe@google.com, paulberry@google.com, sigmund@google.com
BUG=

Review-Url: https://codereview.chromium.org/2975253002 .
2017-07-13 16:28:18 -07:00
Brian Wilkerson d9754a58e9 Initial implementation of copy/paste support
R=devoncarew@google.com

Review-Url: https://codereview.chromium.org/2972833002 .
2017-07-05 14:02:07 -07:00
Brian Wilkerson 7d26ff6d4f Remove some more library directives
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2884233004 .
2017-05-17 08:02:08 -07:00
Brian Wilkerson fb982f5476 Make server use the common protocol classes
R=danrubel@google.com

Review-Url: https://codereview.chromium.org/2879273002 .
2017-05-15 09:35:46 -07:00
Brian Wilkerson e55812a3f2 Unify the server and plugin versions of the generators
R=devoncarew@google.com

Review-Url: https://codereview.chromium.org/2844273003 .
2017-04-28 07:46:29 -07:00
Devon Carew d02519aec4 Make the analysis server integration tests driver only.
BUG=
R=brianwilkerson@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2820893002 .
2017-04-17 11:23:38 -07:00
Devon Carew eb1839b8fd Minor changes to the generated spec, and display deprecated methods better.
BUG=
R=brianwilkerson@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2800283002 .
2017-04-15 13:43:36 -07:00
Devon Carew e572bf93ec Add 4 integration tests for the analysis domain.
BUG=
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2808623002 .
2017-04-08 20:56:00 -07:00
Jacob Richman a993294503 Format all analyzer packages
BUG=
R=brianwilkerson@google.com

Review-Url: https://codereview.chromium.org/2753923003 .
2017-03-16 16:11:43 -07:00
Devon Carew 0f7fc43df5 Remove the --no-error-notification flag.
BUG=
R=brianwilkerson@google.com

Review-Url: https://codereview.chromium.org/2713053002 .
2017-02-23 16:55:46 -08:00
Devon Carew fbb613a3fe Update the statuses of various analysis server integration tests.
BUG=
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2717523003 .
2017-02-23 14:23:55 -08:00
Devon Carew 5e0710617d Tests for analysis.navigation.
BUG=
R=brianwilkerson@google.com, scheglov@google.com

Review-Url: https://codereview.chromium.org/2696323004 .
2017-02-16 14:35:20 -08:00
Brian Wilkerson 06b3f47434 [Gardening] Remove an invalid (and flaky) test
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2681493002 .
2017-02-06 10:09:03 -08:00
Brian Wilkerson 2f81decdd7 Add a test that server does not send errors when errors have been disabled
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2674863004 .
2017-02-04 09:46:55 -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
Brian Wilkerson 5ad638c9d3 Add a failing integration test
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2574843002 .
2016-12-13 11:44:37 -08:00
Konstantin Shcheglov d564b0aaab Send errors notification without delay.
Update 'analysis.updateContent' integration test.

This might be OK from performance POV - errors are cheaper to send than
for example navigation. And this satisfies the goal of 'analyzing'
notification - that new errors are to be expected.

R=brianwilkerson@google.com, paulberry@google.com
BUG=

Review-Url: https://codereview.chromium.org/2567113003 .
2016-12-12 11:39:47 -08:00
Konstantin Shcheglov f43db9ccfa Update the integration test to make the file with subscription a priority one.
R=brianwilkerson@google.com
BUG=

Review-Url: https://codereview.chromium.org/2566243002 .
2016-12-12 10:51:13 -08:00
Konstantin Shcheglov 2a7612f103 Implement 'analysis.occurrences' for the new analysis driver.
R=brianwilkerson@google.com
BUG=

Review-Url: https://codereview.chromium.org/2566223002 .
2016-12-12 10:07:19 -08:00
Konstantin Shcheglov a7222ac09d Implement 'analysis.outline' for the new analysis driver.
R=brianwilkerson@google.com
BUG=

Review-Url: https://codereview.chromium.org/2571513002 .
2016-12-12 09:09:45 -08:00
Konstantin Shcheglov 0728e4ee70 Implement 'analysis.getErrors' for the new driver.
R=brianwilkerson@google.com
BUG=

Review-Url: https://codereview.chromium.org/2566013002 .
2016-12-11 15:27:57 -08:00
Brian Wilkerson 7f36a0d403 Get all integration tests running with the new driver
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2564863003 .
2016-12-09 16:12:52 -08:00
Devon Carew f16a0a2a4d Use an import prefix in the analysis server tests; this fixes some issues conflicting with the
'equals' symbol in the 1.4.0 version of package:path.

BUG=
R=scheglov@google.com

Review URL: https://codereview.chromium.org/2518873002 .
2016-11-20 10:26:27 -08:00
Mohamed Hayibor 5595b9698d Fix typos 'overriden' to 'overridden' and '@mustCall super' to '@mustCallSuper' (#27853)
* fix overriden typos to overridden
* Fix @mustCall super to @mustCallSuper
2016-11-18 09:36:25 -08:00