Files
sdk/tests/language/language_spec_parser.status
T
Erik Ernst 40b6741778 Adds support for syntax error in tests to test.py.
This CL modifies the Dart source used from test.py such that it takes
`syntax error` into account as an expected outcome in test files (so
that we can have `//# 01: syntax error` with a similar meaning as
`//# 01: compile-time error`).

For all tools except the spec_parser, `syntax error` is the same
outcome as `compile-time error`; that is, nobody else will see the
difference.

For the spec_parser, `syntax error` is the outcome where parsing has
failed; `compile-time error` is taken to mean some other compile-time
error, i.e., the spec_parser is expected to _succeed_ when the
expected outcome is `compile-time error`.

Test files in language and language_2 have been adjusted to use the
outcome `syntax error` where appropriate.

The status files in language and language_2 for the spec_parser have
been adjusted such that they fit all the new `syntax error` outcomes
in test files.

Other status files have been adjusted in a few cases where tests were
corrected (because a compile-time error which was clearly not intended
to be a syntax error turned out to be caused by a typo, which means
that the actual compile-time error has never been tested).

The spec grammar Dart.g was adjusted in a few cases, when some bugs
were discovered. In particular, the treatment of Function has been
changed: It is now known by the parser that Function does not take
any type arguments. This makes no difference for developers, because
they cannot declare a type named Function anyway, but it means that
a number of tricky parsing issues were resolved.

Dart.g was also adjusted to allow `qualified` to contain three
identifiers, which is an old bug (preventing things like metadata on
the form `@p.C.myConst`).

Change-Id: Ie420887d45c882ef97c84143365219f8aa0d2933
Reviewed-on: https://dart-review.googlesource.com/18262
Commit-Queue: Erik Ernst <eernst@google.com>
Reviewed-by: Bob Nystrom <rnystrom@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
2017-11-06 08:56:09 +00:00

51 lines
2.7 KiB
Plaintext

# Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
[ $compiler == spec_parser ]
# Negative tests with syntax errors.
factory3_negative_test: Fail # Negative, puts `default` in class header.
field3_negative_test: Fail # Negative, uses `final var a`.
getter_declaration_negative_test: Fail # Negative, uses getter with parameter.
interface_injection1_negative_test: Fail # Negative, uses interface injection.
interface_injection2_negative_test: Fail # Negative, uses interface injection.
is_not_class1_negative_test: Fail # Negative, uses `a is "A"`.
is_not_class4_negative_test: Fail # Negative, uses `a is A is A`.
issue1578_negative_test: Fail # Negative, is line noise.
label8_negative_test: Fail # Negative, uses misplaced label.
list_literal_negative_test: Fail # Negative, uses `new List<int>[1, 2]`.
map_literal_negative_test: Fail # Negative, uses `new Map<int>{..}`.
new_expression1_negative_test: Fail # Negative, uses `new id`.
new_expression2_negative_test: Fail # Negative, uses `new id(`.
new_expression3_negative_test: Fail # Negative, uses `new id(...`.
operator1_negative_test: Fail # Negative, declares static operator.
operator2_negative_test: Fail # Negative, declares `operator ===`.
prefix18_negative_test: Fail # Negative, uses `lib1.invalid` as library prefix.
string_escape4_negative_test: Fail # Negative, uses newline in string literal.
string_interpolate1_negative_test: Fail # Negative, misplaced '$'.
string_interpolate2_negative_test: Fail # Negative, misplaced '$'.
switch1_negative_test: Fail # Negative, `default` clause not last.
test_negative_test: Fail # Negative, uses non-terminated string literal.
unary_plus_negative_test: Fail # Negative, uses non-existing unary plus.
unhandled_exception_negative_test: Fail # Negative, defaults required parameter.
# Tests with unintended syntax errors.
assertion_initializer_const_error2_test/*: Fail # Misplaced comma.
assertion_initializer_const_error2_test/cc02: Pass
# Tests using constructs which are not Dart syntax.
vm/debug_break_enabled_vm_test: Fail # Uses debug break.
const_native_factory_test/01: Fail # Uses `native`.
# Tests containing conditional imports.
conditional_import_string_test: Fail # Not yet supported.
conditional_import_test: Fail # Not yet supported.
config_import_corelib_test: Fail # Not yet supported.
config_import_test: Fail # Not yet supported.
# Not working for miscellaneous other reasons.
deep_nesting1_negative_test: Skip # Stack overflow.
deep_nesting2_negative_test: Skip # Stack overflow.
issue_1751477_test: Skip # Times out: 9 levels, exponential blowup => 430 secs.