Commit Graph

27 Commits

Author SHA1 Message Date
Johnni Winther 543bc03de8 [cfe] Move /fasta/ content into /base/
These files should be further reorganized but that is for a
future CL.

Part of removing uses of 'fasta'.

Change-Id: I5010789b5901ba51c58d98fe26f13177b13c81b3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/373080
Reviewed-by: Jens Johansen <jensj@google.com>
Reviewed-by: Srujan Gaddam <srujzs@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2024-06-27 07:54:23 +00:00
Johnni Winther 43db6c6ba8 [cfe] Split id-testing helpers
This prepares for adding id-test support in ddc.

Change-Id: I96d35b06e5e32f464cd487dc852ec114064afc9d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/334161
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2023-11-06 14:06:46 +00:00
Johnni Winther 9d2da55f70 [cfe] Remove language version from test data
Change-Id: I2288a4fd1fa93044436f161f07b9b3fb7ea441f9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250847
Reviewed-by: Jens Johansen <jensj@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2022-07-08 09:25:29 +00:00
Jens Johansen b4e2012f5b [CFE] Remove support for .packages file
This CL:
* Removed the redirect from .packages to .dart_tool/package_config.json
  (whenever such a file existed).
* Removes support for the old format entirely.
* Updates all tests etc that were found.

Fixes https://github.com/dart-lang/sdk/issues/48939

TEST=Existing tests updated.

Change-Id: Iccf711c455ac1885189aa773ca74dd8f55012964
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248603
Reviewed-by: Michael Thomsen <mit@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2022-06-24 08:20:39 +00:00
Jens Johansen ac586ff2a6 [CFE] Remove many uses of .packages files in tests
Change-Id: I9c74b373d087984498debd987df55520c33ad1af
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/249190
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2022-06-22 07:34:49 +00:00
Johnni Winther 3e2f98d652 [cfe] Add support for custom data in id testing
This allows for using data created in the TestConfig in the computation
of test results.

Change-Id: Ia4820d0b739b01272f10d2c2561fcf77ae007031
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/225731
Reviewed-by: Chloe Stefantsova <cstefantsova@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2021-12-31 15:12:32 +00:00
Johnni Winther 450ff2976d [cfe] Migrate (more) CFE tests (part 11)
Change-Id: I905adcd2125ce66d6ba9923d996354657b679cec
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/220965
Reviewed-by: Jens Johansen <jensj@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2021-11-24 11:15:41 +00:00
Jens Johansen 1197e15a7e [CFE] Enable avoid_void_async lint
This CL enables the avoid_void_async lint in the CFE, makes the needed
changes and adds the missing `await` (because the lint
`unawaited_futures` doesn't react to void async methods).

Change-Id: Iffc1f173badd3c2d48356ee02e81a9aed492ce5d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/213481
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2021-09-23 11:58:18 +00:00
Sam Rawlins 9f0c408376 Remove redundant imports from front_end
Very often there were two imports of the same URI, one of which also
had a `show` combinator. I opted to remove the other one.

Bug: https://github.com/dart-lang/sdk/issues/44569
Change-Id: I1263c892f94f0645fda6dee371dfc1fcddcd2344
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/213846
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2021-09-20 15:33:43 +00:00
Johnni Winther a6cc772b67 [cfe] Add always_declare_return_types lint
Change-Id: I206a7a8132b5ea79dc019acf5c2e0cd800307bcf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212161
Reviewed-by: Jens Johansen <jensj@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2021-09-02 08:07:23 +00:00
Johnni Winther 3eac19026b [cfe] Add annotate_overrides lint
Change-Id: I90a6d5c7d64ed23acd94b9a8dda58d53da4fe8df
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212041
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2021-09-01 16:24:16 +00:00
Johnni Winther 34fb48bb8a [kernel,front_end] Migrate first wave of pkg/kernel and pkg/front_end
Migrates libraries dependent only on already migrated libraries.

Change-Id: I0e85ee8dbc2afce031b92e0009e71c206a55af28
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/179502
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2021-01-18 15:40:21 +00:00
Joshua Litt 043bebcd02 [dart2js] Fixes to dart2js unit tests to support nnbd by default.
Change-Id: I440dddd34a62bfe8c0f3fd563888acb680c2b031
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/168141
Commit-Queue: Joshua Litt <joshualitt@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2020-10-20 18:40:44 +00:00
Joshua Litt 20faaa5d94 [dart2js] Move dart2js unit tests to pkg/compiler/test.
Change-Id: Ib18f554c1076f27a3f7c0df5a36410da41a1f467
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148784
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2020-05-28 18:51:11 +00:00
Joshua Litt 32c3a2cde7 [dart2js] Rebase nnbd expectations for 3 tests.
cfe_constant_test
inlining_test
jfield_analysis

Change-Id: Ib2833507f4e19f3d6a1e5055977bccc962b2d791
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/144494
Commit-Queue: Joshua Litt <joshualitt@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2020-04-24 18:30:03 +00:00
Joshua Litt 6f5f7ad05c [dart2js] rebase deferred_loading_test for nnbd.
Change-Id: Ia8cd18e19554afec57675bab64797984445556c5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/143820
Commit-Queue: Joshua Litt <joshualitt@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2020-04-23 01:17:58 +00:00
Johnni Winther 5829fc7829 [analyzer,cfe,dart2js] Add marker.options files to automate running id tests on all configurations
Change-Id: Ib5eb7f3967634721047f8dcc57b9e6c350b91a41
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/136226
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2020-02-21 08:34:26 +00:00
Johnni Winther 5e389080a4 [cfe] Test supertypes computed from ClassHierarchyBuilder
Change-Id: Ia079754bd8272d7b5689a3bdab1e69d5188082be
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/132342
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2020-01-22 07:08:36 +00:00
Johnni Winther e3a20bf361 [analyzer,cfe,dart2js] Support annotated code generation
Add support for generating annotations from actual data using
option -g

Change-Id: I88d9cdb62a38d579234b15097c9e9bb3d81ebe8c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/129708
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2020-01-03 13:57:39 +00:00
Paul Berry c4b6df5009 Move ID testing infrastructure into _fe_analyzer_shared.
Change-Id: I9f2692dbe750f3c31f8c86e86fe732f34e166517
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/123860
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-11-01 12:39:00 +00:00
Johnni Winther dd028547ce [cfe] Support patching of extension methods
Change-Id: I453e17e63f97a0ca2477371541c6a9602bee2404
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/119322
Reviewed-by: Jens Johansen <jensj@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2019-09-30 09:51:31 +00:00
Johnni Winther 19654f30d0 [cfe+vm+ddc] Return ClassHierarchy and CoreTypes together with Component
Users of the CFE often need the ClassHierarchy and may CoreTypes after
invoking the CFE. This CL extends the result of `kernelForProgram` and
`kernelForComponent` to a `CompilerResult` that includes these objects.

Change-Id: I08491198fe876b6514e49993ad794388d6662c9c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/112259
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2019-08-09 13:02:12 +00:00
Jens Johansen a69c81ac34 Id testing for directories with .packages etc
We should also be able to test for larger examples, so this CL adds
support for directories where all files are included. If the directory
contains a .packages file that is used so we can test packages too.

Change-Id: Iceda03505575bd9e5604a6e374b7f5fa7185a82e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/111421
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-08-01 09:25:28 +00:00
Johnni Winther 5357056a20 [cfe] Report errors when extension declarations are used as types
Change-Id: Iad0c7df54fac476c2f23af2fe4ba30ee5bf49167
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/110222
Reviewed-by: Dan Rubel <danrubel@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2019-07-25 17:20:54 +00:00
Johnni Winther 82f657d7cb [cfe] Support error testing in annotated tests
Change-Id: I545ded4d82147f22efc80f4ed8ee833cd75a9be7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/109963
Reviewed-by: Dan Rubel <danrubel@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2019-07-24 07:10:23 +00:00
Johnni Winther dfa12c7456 [cfe+dart2js] Support library and error ids in annotated tests
Change-Id: Ife808a7d4aa1d4cf459ac3c04ee6ff02042442d9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/108810
Reviewed-by: Stephen Adams <sra@google.com>
2019-07-16 14:32:37 +00:00
Johnni Winther 4686393ccb [cfe] Add test for the id testing system.
Change-Id: Ie4f3042d4fd0f78e55cd672947fde3fab7950fb3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/108802
Reviewed-by: Jens Johansen <jensj@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2019-07-12 07:54:28 +00:00