question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

No tests match regular expression " test & exit /B 0".

See original GitHub issue

Hi

vscode is having a problem running tests with a multi-line string description.

How to reproduce:

This will pass:

import 'package:flutter_test/flutter_test.dart';

void main() {
  testWidgets('''test''', (tester) async {});
}

This will not pass:

import 'package:flutter_test/flutter_test.dart';

void main() {

    testWidgets('''
        test
        ''', (tester) async {});

}

keep in mind that the later test will pass if run through void main.

[√] VS Code (version 1.67.2)
    • VS Code at C:\Users\m_ben\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.42.0

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
jeff9315commented, Aug 28, 2022

I am still having this problem on 3.46.1 using Windows 11. Multiline comments of 3 or more lines fail with this error message when run individually but work when run from a group or from main() in the test file.

1reaction
DanTupcommented, Jun 7, 2022

Actually, I can repro on Windows, and only Flutter tests, not Dart tests.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Flutter test with mockito error No test match regular expression
Hello guys i want to do a test thats verify that i used a method but i only get an error ... No...
Read more >
VS Code extensions v3.44.0 - Google Groups
#4007: Running Flutter tests with multiline names on Windows no longer fails with “No tests match regular expression 'test & exit /B 0'”....
Read more >
Test a regular expression slot type
You can test expressions when you create regular expression slot types in Genesys ... regular expression or you leave it in edit mode,...
Read more >
Understanding Regular Expression matching with .test, .match ...
I'm going to cover the use cases for testing RegExps in a few ways, each with a specific use case. This will include...
Read more >
Regular Expression (Regex) Tutorial
[^...]: NOT ONE of the character, e.g., [^0-9] matches any non-digit. Only these four characters require escape sequence inside the bracket list: ^...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found