且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

我无法在Dart插件中运行单个测试文件

更新时间:2023-02-22 20:02:13

确定,所以我实际上找到了解决方案。

OK so I actually found a solution for this.

在Android Studio的运行下拉列表中,选择编辑配置

,然后按 + 按钮,然后选择 Flutter测试

确保测试范围为全部在文件中,并将其指向您的测试文件。

现在,您可以运行单个测试文件,也可以通过在运行下拉菜单中选择此配置,在android studio中对其进行调试。

In Android studio in the run dropdown you select Edit Configurations
Then you press the + button and select Flutter test
Make sure the Test scope is All in file and point it at your test file.
You can now run the individual test file and also debug it in android studio by selecting this configuration in the run drop-down.