diff --git a/tests/language/async_nested/async_nested01_test.dart b/tests/language/async_nested/async_nested01_test.dart new file mode 100644 index 00000000000..4369751e780 --- /dev/null +++ b/tests/language/async_nested/async_nested01_test.dart @@ -0,0 +1,46 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10"; + Node node = new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [ + await new Future.value(new Node('4', [ + new Node('5', [ + await new Future.value(new Node('6', [ + await new Future.value(new Node('7', [])), + ])), + await new Future.value(new Node('8', [])), + await new Future.value(new Node('9', [])), + ]), + ])), + ])), + await new Future.value(new Node('10', [])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested02_test.dart b/tests/language/async_nested/async_nested02_test.dart new file mode 100644 index 00000000000..0d98bcc4e18 --- /dev/null +++ b/tests/language/async_nested/async_nested02_test.dart @@ -0,0 +1,46 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11"; + Node node = new Node('1', [ + new Node('2', [ + new Node('3', []), + ]), + await new Future.value(new Node('4', [ + await new Future.value(new Node('5', [])), + new Node('6', [ + new Node('7', []), + await new Future.value(new Node('8', [])), + ]), + await new Future.value(new Node('9', [])), + ])), + await new Future.value(new Node('10', [])), + new Node('11', []), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested03_test.dart b/tests/language/async_nested/async_nested03_test.dart new file mode 100644 index 00000000000..1fc44f52f60 --- /dev/null +++ b/tests/language/async_nested/async_nested03_test.dart @@ -0,0 +1,48 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12"; + Node node = new Node('1', [ + new Node('2', [ + await new Future.value(new Node('3', [])), + await new Future.value(new Node('4', [ + new Node('5', []), + await new Future.value(new Node('6', [])), + await new Future.value(new Node('7', [])), + new Node('8', []), + ])), + new Node('9', []), + new Node('10', [ + new Node('11', [ + await new Future.value(new Node('12', [])), + ]), + ]), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested04_test.dart b/tests/language/async_nested/async_nested04_test.dart new file mode 100644 index 00000000000..6cbbef278ea --- /dev/null +++ b/tests/language/async_nested/async_nested04_test.dart @@ -0,0 +1,46 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [])), + await new Future.value(new Node('3', [])), + await new Future.value(new Node('4', [ + await new Future.value(new Node('5', [])), + new Node('6', []), + new Node('7', [ + new Node('8', []), + await new Future.value(new Node('9', [])), + ]), + await new Future.value(new Node('10', [])), + ])), + new Node('11', []), + await new Future.value(new Node('12', [])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested05_test.dart b/tests/language/async_nested/async_nested05_test.dart new file mode 100644 index 00000000000..b57f225f3dc --- /dev/null +++ b/tests/language/async_nested/async_nested05_test.dart @@ -0,0 +1,46 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [])), + await new Future.value(new Node('3', [ + await new Future.value(new Node('4', [])), + await new Future.value(new Node('5', [])), + await new Future.value(new Node('6', [])), + ])), + new Node('7', []), + new Node('8', [ + new Node('9', []), + await new Future.value(new Node('10', [])), + new Node('11', []), + await new Future.value(new Node('12', [])), + ]), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested06_test.dart b/tests/language/async_nested/async_nested06_test.dart new file mode 100644 index 00000000000..70eb9c98217 --- /dev/null +++ b/tests/language/async_nested/async_nested06_test.dart @@ -0,0 +1,49 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12"; + Node node = new Node('1', [ + new Node('2', [ + await new Future.value(new Node('3', [ + new Node('4', []), + ])), + new Node('5', [ + await new Future.value(new Node('6', [ + await new Future.value(new Node('7', [ + new Node('8', []), + ])), + new Node('9', []), + await new Future.value(new Node('10', [])), + ])), + await new Future.value(new Node('11', [])), + await new Future.value(new Node('12', [])), + ]), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested07_test.dart b/tests/language/async_nested/async_nested07_test.dart new file mode 100644 index 00000000000..5c93a6d98c5 --- /dev/null +++ b/tests/language/async_nested/async_nested07_test.dart @@ -0,0 +1,48 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [])), + await new Future.value(new Node('3', [ + new Node('4', []), + new Node('5', []), + await new Future.value(new Node('6', [])), + new Node('7', [ + await new Future.value(new Node('8', [ + new Node('9', []), + ])), + await new Future.value(new Node('10', [])), + ]), + ])), + new Node('11', [ + await new Future.value(new Node('12', [])), + ]), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested08_test.dart b/tests/language/async_nested/async_nested08_test.dart new file mode 100644 index 00000000000..170a7355bb7 --- /dev/null +++ b/tests/language/async_nested/async_nested08_test.dart @@ -0,0 +1,48 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [ + await new Future.value(new Node('3', [])), + ])), + await new Future.value(new Node('4', [ + await new Future.value(new Node('5', [])), + await new Future.value(new Node('6', [])), + new Node('7', []), + new Node('8', []), + new Node('9', [ + await new Future.value(new Node('10', [])), + ]), + new Node('11', []), + new Node('12', []), + ])), + await new Future.value(new Node('13', [])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested09_test.dart b/tests/language/async_nested/async_nested09_test.dart new file mode 100644 index 00000000000..f44e7253e3e --- /dev/null +++ b/tests/language/async_nested/async_nested09_test.dart @@ -0,0 +1,49 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13"; + Node node = new Node('1', [ + new Node('2', [ + await new Future.value(new Node('3', [])), + await new Future.value(new Node('4', [ + new Node('5', []), + new Node('6', []), + new Node('7', []), + new Node('8', []), + await new Future.value(new Node('9', [ + new Node('10', [ + new Node('11', []), + ]), + ])), + await new Future.value(new Node('12', [])), + ])), + await new Future.value(new Node('13', [])), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested10_test.dart b/tests/language/async_nested/async_nested10_test.dart new file mode 100644 index 00000000000..419d36a9c26 --- /dev/null +++ b/tests/language/async_nested/async_nested10_test.dart @@ -0,0 +1,51 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [ + new Node('3', []), + await new Future.value(new Node('4', [ + await new Future.value(new Node('5', [ + new Node('6', []), + new Node('7', [ + new Node('8', []), + ]), + await new Future.value(new Node('9', [])), + new Node('10', [ + new Node('11', []), + ]), + ])), + ])), + await new Future.value(new Node('12', [ + new Node('13', []), + ])), + ])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested11_test.dart b/tests/language/async_nested/async_nested11_test.dart new file mode 100644 index 00000000000..4349917839a --- /dev/null +++ b/tests/language/async_nested/async_nested11_test.dart @@ -0,0 +1,50 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [ + new Node('3', []), + new Node('4', [ + new Node('5', []), + new Node('6', []), + await new Future.value(new Node('7', [ + new Node('8', [ + new Node('9', []), + ]), + new Node('10', []), + new Node('11', [ + await new Future.value(new Node('12', [])), + ]), + ])), + await new Future.value(new Node('13', [])), + ]), + ])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested12_test.dart b/tests/language/async_nested/async_nested12_test.dart new file mode 100644 index 00000000000..cf6a305edcf --- /dev/null +++ b/tests/language/async_nested/async_nested12_test.dart @@ -0,0 +1,49 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [])), + await new Future.value(new Node('3', [])), + new Node('4', [ + await new Future.value(new Node('5', [ + new Node('6', []), + new Node('7', []), + await new Future.value(new Node('8', [ + new Node('9', []), + ])), + ])), + new Node('10', [ + new Node('11', []), + await new Future.value(new Node('12', [])), + ]), + ]), + await new Future.value(new Node('13', [])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested13_test.dart b/tests/language/async_nested/async_nested13_test.dart new file mode 100644 index 00000000000..f3fcfe78d41 --- /dev/null +++ b/tests/language/async_nested/async_nested13_test.dart @@ -0,0 +1,52 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14"; + Node node = new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [])), + await new Future.value(new Node('4', [ + new Node('5', [ + await new Future.value(new Node('6', [ + new Node('7', [ + new Node('8', [ + new Node('9', []), + new Node('10', []), + await new Future.value(new Node('11', [])), + ]), + await new Future.value(new Node('12', [])), + ]), + ])), + await new Future.value(new Node('13', [ + new Node('14', []), + ])), + ]), + ])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested14_test.dart b/tests/language/async_nested/async_nested14_test.dart new file mode 100644 index 00000000000..5b8ad8d3ec3 --- /dev/null +++ b/tests/language/async_nested/async_nested14_test.dart @@ -0,0 +1,50 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14"; + Node node = new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [ + new Node('4', [ + await new Future.value(new Node('5', [])), + new Node('6', []), + new Node('7', []), + new Node('8', [ + await new Future.value(new Node('9', [ + new Node('10', []), + await new Future.value(new Node('11', [])), + ])), + ]), + await new Future.value(new Node('12', [])), + ]), + new Node('13', []), + ])), + await new Future.value(new Node('14', [])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested15_test.dart b/tests/language/async_nested/async_nested15_test.dart new file mode 100644 index 00000000000..3830a53c15c --- /dev/null +++ b/tests/language/async_nested/async_nested15_test.dart @@ -0,0 +1,52 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [ + await new Future.value(new Node('3', [ + new Node('4', []), + await new Future.value(new Node('5', [ + await new Future.value(new Node('6', [])), + new Node('7', [ + new Node('8', []), + await new Future.value(new Node('9', [])), + new Node('10', []), + new Node('11', [ + new Node('12', []), + ]), + ]), + ])), + new Node('13', [ + await new Future.value(new Node('14', [])), + ]), + ])), + ])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested16_test.dart b/tests/language/async_nested/async_nested16_test.dart new file mode 100644 index 00000000000..25ad09dbb09 --- /dev/null +++ b/tests/language/async_nested/async_nested16_test.dart @@ -0,0 +1,51 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14"; + Node node = await new Future.value(new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [ + new Node('4', []), + new Node('5', []), + new Node('6', []), + new Node('7', []), + new Node('8', [ + await new Future.value(new Node('9', [ + await new Future.value(new Node('10', [])), + ])), + ]), + new Node('11', []), + ])), + new Node('12', [ + new Node('13', [ + await new Future.value(new Node('14', [])), + ]), + ]), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested17_test.dart b/tests/language/async_nested/async_nested17_test.dart new file mode 100644 index 00000000000..935121fcb36 --- /dev/null +++ b/tests/language/async_nested/async_nested17_test.dart @@ -0,0 +1,49 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14"; + Node node = await new Future.value(new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [ + new Node('4', [ + await new Future.value(new Node('5', [])), + new Node('6', []), + new Node('7', []), + ]), + await new Future.value(new Node('8', [])), + new Node('9', [ + new Node('10', []), + await new Future.value(new Node('11', [])), + ]), + await new Future.value(new Node('12', [])), + ])), + await new Future.value(new Node('13', [])), + new Node('14', []), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested18_test.dart b/tests/language/async_nested/async_nested18_test.dart new file mode 100644 index 00000000000..8377fab4dec --- /dev/null +++ b/tests/language/async_nested/async_nested18_test.dart @@ -0,0 +1,53 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = new Node('1', [ + new Node('2', []), + new Node('3', [ + await new Future.value(new Node('4', [])), + new Node('5', [ + new Node('6', [ + new Node('7', [ + await new Future.value(new Node('8', [ + new Node('9', []), + new Node('10', []), + await new Future.value(new Node('11', [])), + await new Future.value(new Node('12', [])), + new Node('13', []), + ])), + await new Future.value(new Node('14', [ + new Node('15', []), + ])), + ]), + ]), + ]), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested19_test.dart b/tests/language/async_nested/async_nested19_test.dart new file mode 100644 index 00000000000..18219134fbc --- /dev/null +++ b/tests/language/async_nested/async_nested19_test.dart @@ -0,0 +1,53 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = await new Future.value(new Node('1', [ + new Node('2', []), + new Node('3', []), + new Node('4', [ + new Node('5', []), + ]), + new Node('6', [ + new Node('7', []), + ]), + new Node('8', [ + new Node('9', [ + await new Future.value(new Node('10', [ + new Node('11', [ + new Node('12', []), + new Node('13', []), + await new Future.value(new Node('14', [])), + ]), + ])), + await new Future.value(new Node('15', [])), + ]), + ]), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested20_test.dart b/tests/language/async_nested/async_nested20_test.dart new file mode 100644 index 00000000000..d80f6edeb7b --- /dev/null +++ b/tests/language/async_nested/async_nested20_test.dart @@ -0,0 +1,53 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [ + new Node('3', []), + await new Future.value(new Node('4', [ + await new Future.value(new Node('5', [ + new Node('6', []), + new Node('7', [ + await new Future.value(new Node('8', [ + new Node('9', []), + ])), + new Node('10', []), + new Node('11', []), + new Node('12', [ + await new Future.value(new Node('13', [])), + new Node('14', []), + ]), + ]), + ])), + await new Future.value(new Node('15', [])), + ])), + ])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested21_test.dart b/tests/language/async_nested/async_nested21_test.dart new file mode 100644 index 00000000000..55210ef7701 --- /dev/null +++ b/tests/language/async_nested/async_nested21_test.dart @@ -0,0 +1,54 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [ + new Node('3', [ + new Node('4', [ + await new Future.value(new Node('5', [])), + new Node('6', [ + await new Future.value(new Node('7', [ + new Node('8', [ + await new Future.value(new Node('9', [])), + new Node('10', []), + ]), + new Node('11', []), + await new Future.value(new Node('12', [])), + new Node('13', []), + ])), + new Node('14', [ + await new Future.value(new Node('15', [])), + ]), + ]), + ]), + ]), + ])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested22_test.dart b/tests/language/async_nested/async_nested22_test.dart new file mode 100644 index 00000000000..e587a71c503 --- /dev/null +++ b/tests/language/async_nested/async_nested22_test.dart @@ -0,0 +1,52 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [])), + new Node('3', []), + await new Future.value(new Node('4', [ + await new Future.value(new Node('5', [])), + new Node('6', [ + new Node('7', [ + new Node('8', [ + new Node('9', []), + ]), + ]), + await new Future.value(new Node('10', [ + new Node('11', []), + ])), + await new Future.value(new Node('12', [])), + ]), + new Node('13', []), + ])), + await new Future.value(new Node('14', [])), + new Node('15', []), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested23_test.dart b/tests/language/async_nested/async_nested23_test.dart new file mode 100644 index 00000000000..da3b892109b --- /dev/null +++ b/tests/language/async_nested/async_nested23_test.dart @@ -0,0 +1,51 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [])), + await new Future.value(new Node('3', [ + new Node('4', [ + new Node('5', [ + new Node('6', []), + new Node('7', [ + new Node('8', []), + ]), + new Node('9', []), + await new Future.value(new Node('10', [])), + new Node('11', []), + ]), + ]), + new Node('12', []), + await new Future.value(new Node('13', [])), + ])), + await new Future.value(new Node('14', [])), + new Node('15', []), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested24_test.dart b/tests/language/async_nested/async_nested24_test.dart new file mode 100644 index 00000000000..d90e1f9c370 --- /dev/null +++ b/tests/language/async_nested/async_nested24_test.dart @@ -0,0 +1,50 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = await new Future.value(new Node('1', [ + new Node('2', []), + new Node('3', []), + await new Future.value(new Node('4', [ + await new Future.value(new Node('5', [])), + new Node('6', []), + await new Future.value(new Node('7', [])), + await new Future.value(new Node('8', [])), + ])), + new Node('9', []), + new Node('10', [ + await new Future.value(new Node('11', [])), + new Node('12', [ + await new Future.value(new Node('13', [])), + new Node('14', []), + await new Future.value(new Node('15', [])), + ]), + ]), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested25_test.dart b/tests/language/async_nested/async_nested25_test.dart new file mode 100644 index 00000000000..db5b481d499 --- /dev/null +++ b/tests/language/async_nested/async_nested25_test.dart @@ -0,0 +1,53 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = new Node('1', [ + new Node('2', [ + new Node('3', [ + new Node('4', []), + await new Future.value(new Node('5', [ + await new Future.value(new Node('6', [ + new Node('7', [ + await new Future.value(new Node('8', [])), + new Node('9', []), + await new Future.value(new Node('10', [])), + await new Future.value(new Node('11', [])), + new Node('12', [ + await new Future.value(new Node('13', [])), + ]), + new Node('14', []), + ]), + ])), + await new Future.value(new Node('15', [])), + ])), + ]), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested26_test.dart b/tests/language/async_nested/async_nested26_test.dart new file mode 100644 index 00000000000..aaf402da030 --- /dev/null +++ b/tests/language/async_nested/async_nested26_test.dart @@ -0,0 +1,50 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14"; + Node node = new Node('1', [ + new Node('2', [ + await new Future.value(new Node('3', [])), + ]), + await new Future.value(new Node('4', [ + await new Future.value(new Node('5', [ + new Node('6', [ + new Node('7', []), + ]), + new Node('8', []), + await new Future.value(new Node('9', [])), + new Node('10', []), + new Node('11', []), + ])), + await new Future.value(new Node('12', [])), + new Node('13', []), + new Node('14', []), + ])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested27_test.dart b/tests/language/async_nested/async_nested27_test.dart new file mode 100644 index 00000000000..f2e59cf2428 --- /dev/null +++ b/tests/language/async_nested/async_nested27_test.dart @@ -0,0 +1,53 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [ + new Node('4', []), + await new Future.value(new Node('5', [ + new Node('6', []), + await new Future.value(new Node('7', [ + new Node('8', []), + ])), + ])), + ])), + await new Future.value(new Node('9', [ + new Node('10', [ + new Node('11', []), + new Node('12', []), + await new Future.value(new Node('13', [])), + await new Future.value(new Node('14', [])), + await new Future.value(new Node('15', [])), + new Node('16', []), + ]), + ])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested28_test.dart b/tests/language/async_nested/async_nested28_test.dart new file mode 100644 index 00000000000..8f94d8b2e51 --- /dev/null +++ b/tests/language/async_nested/async_nested28_test.dart @@ -0,0 +1,54 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [ + new Node('3', []), + new Node('4', []), + new Node('5', [ + new Node('6', []), + await new Future.value(new Node('7', [ + new Node('8', [ + new Node('9', []), + new Node('10', [ + new Node('11', [ + new Node('12', []), + new Node('13', []), + await new Future.value(new Node('14', [])), + ]), + ]), + ]), + ])), + new Node('15', []), + await new Future.value(new Node('16', [])), + ]), + ])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested29_test.dart b/tests/language/async_nested/async_nested29_test.dart new file mode 100644 index 00000000000..aa2bc6f8550 --- /dev/null +++ b/tests/language/async_nested/async_nested29_test.dart @@ -0,0 +1,55 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [ + new Node('3', []), + await new Future.value(new Node('4', [])), + new Node('5', [ + new Node('6', []), + await new Future.value(new Node('7', [ + new Node('8', [ + await new Future.value(new Node('9', [])), + await new Future.value(new Node('10', [ + new Node('11', [ + new Node('12', [ + await new Future.value(new Node('13', [])), + ]), + new Node('14', []), + await new Future.value(new Node('15', [])), + ]), + ])), + await new Future.value(new Node('16', [])), + ]), + ])), + ]), + ])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested30_test.dart b/tests/language/async_nested/async_nested30_test.dart new file mode 100644 index 00000000000..d43e9c0a6d6 --- /dev/null +++ b/tests/language/async_nested/async_nested30_test.dart @@ -0,0 +1,54 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = new Node('1', [ + new Node('2', [ + new Node('3', []), + new Node('4', []), + new Node('5', [ + await new Future.value(new Node('6', [ + new Node('7', []), + new Node('8', [ + await new Future.value(new Node('9', [])), + await new Future.value(new Node('10', [])), + await new Future.value(new Node('11', [])), + ]), + await new Future.value(new Node('12', [])), + new Node('13', []), + ])), + new Node('14', [ + await new Future.value(new Node('15', [ + new Node('16', []), + ])), + ]), + ]), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested31_test.dart b/tests/language/async_nested/async_nested31_test.dart new file mode 100644 index 00000000000..833b62f119c --- /dev/null +++ b/tests/language/async_nested/async_nested31_test.dart @@ -0,0 +1,53 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [])), + await new Future.value(new Node('3', [ + new Node('4', [ + new Node('5', []), + new Node('6', []), + await new Future.value(new Node('7', [])), + await new Future.value(new Node('8', [ + new Node('9', []), + ])), + new Node('10', [ + new Node('11', [ + new Node('12', []), + ]), + ]), + ]), + ])), + await new Future.value(new Node('13', [])), + await new Future.value(new Node('14', [])), + new Node('15', []), + await new Future.value(new Node('16', [])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested32_test.dart b/tests/language/async_nested/async_nested32_test.dart new file mode 100644 index 00000000000..fcec85ee662 --- /dev/null +++ b/tests/language/async_nested/async_nested32_test.dart @@ -0,0 +1,54 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = new Node('1', [ + new Node('2', [ + new Node('3', []), + new Node('4', []), + await new Future.value(new Node('5', [ + await new Future.value(new Node('6', [ + await new Future.value(new Node('7', [])), + new Node('8', [ + new Node('9', []), + await new Future.value(new Node('10', [])), + ]), + ])), + ])), + await new Future.value(new Node('11', [])), + new Node('12', [ + new Node('13', []), + await new Future.value(new Node('14', [ + await new Future.value(new Node('15', [])), + ])), + new Node('16', []), + ]), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested33_test.dart b/tests/language/async_nested/async_nested33_test.dart new file mode 100644 index 00000000000..b72943aace2 --- /dev/null +++ b/tests/language/async_nested/async_nested33_test.dart @@ -0,0 +1,55 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = new Node('1', [ + new Node('2', []), + new Node('3', [ + await new Future.value(new Node('4', [])), + new Node('5', [ + new Node('6', [ + new Node('7', [ + await new Future.value(new Node('8', [])), + await new Future.value(new Node('9', [ + await new Future.value(new Node('10', [ + new Node('11', []), + ])), + await new Future.value(new Node('12', [])), + await new Future.value(new Node('13', [ + await new Future.value(new Node('14', [])), + ])), + ])), + await new Future.value(new Node('15', [])), + new Node('16', []), + ]), + ]), + ]), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested34_test.dart b/tests/language/async_nested/async_nested34_test.dart new file mode 100644 index 00000000000..d13eb14fc5c --- /dev/null +++ b/tests/language/async_nested/async_nested34_test.dart @@ -0,0 +1,54 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [ + new Node('3', []), + new Node('4', []), + new Node('5', [ + await new Future.value(new Node('6', [ + new Node('7', [ + new Node('8', []), + new Node('9', [ + new Node('10', []), + await new Future.value(new Node('11', [])), + ]), + ]), + await new Future.value(new Node('12', [])), + ])), + new Node('13', [ + await new Future.value(new Node('14', [])), + await new Future.value(new Node('15', [])), + new Node('16', []), + ]), + ]), + ])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested35_test.dart b/tests/language/async_nested/async_nested35_test.dart new file mode 100644 index 00000000000..07c06a2bd94 --- /dev/null +++ b/tests/language/async_nested/async_nested35_test.dart @@ -0,0 +1,54 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = await new Future.value(new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [ + await new Future.value(new Node('4', [])), + await new Future.value(new Node('5', [ + new Node('6', []), + new Node('7', []), + await new Future.value(new Node('8', [])), + await new Future.value(new Node('9', [])), + ])), + new Node('10', [ + new Node('11', [ + new Node('12', [ + new Node('13', []), + ]), + ]), + new Node('14', [ + await new Future.value(new Node('15', [])), + ]), + new Node('16', []), + ]), + ])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested36_test.dart b/tests/language/async_nested/async_nested36_test.dart new file mode 100644 index 00000000000..92a320fbac0 --- /dev/null +++ b/tests/language/async_nested/async_nested36_test.dart @@ -0,0 +1,52 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15"; + Node node = await new Future.value(new Node('1', [ + await new Future.value(new Node('2', [ + await new Future.value(new Node('3', [])), + new Node('4', []), + await new Future.value(new Node('5', [ + new Node('6', [ + new Node('7', []), + await new Future.value(new Node('8', [])), + ]), + new Node('9', []), + await new Future.value(new Node('10', [])), + ])), + new Node('11', [ + new Node('12', []), + ]), + new Node('13', [ + await new Future.value(new Node('14', [])), + ]), + ])), + await new Future.value(new Node('15', [])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested37_test.dart b/tests/language/async_nested/async_nested37_test.dart new file mode 100644 index 00000000000..3c0a33eb0a8 --- /dev/null +++ b/tests/language/async_nested/async_nested37_test.dart @@ -0,0 +1,53 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [])), + new Node('4', [ + new Node('5', [ + new Node('6', []), + new Node('7', []), + ]), + ]), + await new Future.value(new Node('8', [ + await new Future.value(new Node('9', [])), + await new Future.value(new Node('10', [ + new Node('11', []), + new Node('12', []), + await new Future.value(new Node('13', [])), + ])), + ])), + await new Future.value(new Node('14', [])), + new Node('15', [ + new Node('16', []), + ]), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested38_test.dart b/tests/language/async_nested/async_nested38_test.dart new file mode 100644 index 00000000000..c74c7631990 --- /dev/null +++ b/tests/language/async_nested/async_nested38_test.dart @@ -0,0 +1,52 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16"; + Node node = await new Future.value(new Node('1', [ + new Node('2', []), + new Node('3', [ + new Node('4', []), + ]), + new Node('5', []), + new Node('6', []), + await new Future.value(new Node('7', [])), + await new Future.value(new Node('8', [ + await new Future.value(new Node('9', [])), + new Node('10', [ + new Node('11', []), + await new Future.value(new Node('12', [])), + ]), + ])), + new Node('13', [ + new Node('14', []), + ]), + await new Future.value(new Node('15', [])), + await new Future.value(new Node('16', [])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested39_test.dart b/tests/language/async_nested/async_nested39_test.dart new file mode 100644 index 00000000000..833453a0a8a --- /dev/null +++ b/tests/language/async_nested/async_nested39_test.dart @@ -0,0 +1,43 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9"; + Node node = await new Future.value(new Node('1', [ + new Node('2', []), + await new Future.value(new Node('3', [ + new Node('4', []), + new Node('5', []), + await new Future.value(new Node('6', [ + new Node('7', []), + ])), + ])), + new Node('8', []), + await new Future.value(new Node('9', [])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested40_test.dart b/tests/language/async_nested/async_nested40_test.dart new file mode 100644 index 00000000000..b049362153f --- /dev/null +++ b/tests/language/async_nested/async_nested40_test.dart @@ -0,0 +1,44 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9"; + Node node = await new Future.value(new Node('1', [ + new Node('2', [ + new Node('3', [ + new Node('4', []), + ]), + ]), + await new Future.value(new Node('5', [ + new Node('6', []), + new Node('7', []), + await new Future.value(new Node('8', [])), + ])), + await new Future.value(new Node('9', [])), + ])); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tests/language/async_nested/async_nested41_test.dart b/tests/language/async_nested/async_nested41_test.dart new file mode 100644 index 00000000000..a3816afea2a --- /dev/null +++ b/tests/language/async_nested/async_nested41_test.dart @@ -0,0 +1,43 @@ +// Copyright (c) 2018, 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. + +// This has been automatically generated by script +// "async_nested_test_generator.dart". + +import 'dart:async'; + +void main() async { + String expected = "1 2 3 4 5 6 7 8 9"; + Node node = new Node('1', [ + await new Future.value(new Node('2', [])), + await new Future.value(new Node('3', [ + new Node('4', []), + await new Future.value(new Node('5', [ + new Node('6', []), + ])), + await new Future.value(new Node('7', [])), + new Node('8', []), + ])), + await new Future.value(new Node('9', [])), + ]); + String actual = node.toSimpleString(); + print(actual); + if (actual != expected) { + throw "Expected '$expected' but got '$actual'"; + } +} + +class Node { + final List? nested; + final String name; + + Node(this.name, [this.nested]) {} + + String toString() => '<$name:[${nested?.join(', ')}]>'; + + toSimpleString() { + var tmp = nested?.map((child) => child.toSimpleString()); + return '$name ${tmp?.join(' ')}'.trim(); + } +} diff --git a/tools/test_generators/async_nested_test_generator.dart b/tools/test_generators/async_nested_test_generator.dart index 2d09a390fea..658e917b39b 100644 --- a/tools/test_generators/async_nested_test_generator.dart +++ b/tools/test_generators/async_nested_test_generator.dart @@ -117,7 +117,7 @@ void main() async { } class Node { - final List nested; + final List? nested; final String name; Node(this.name, [this.nested]) {