mirror of
https://github.com/HendrikRauh/inventree-app.git
synced 2026-01-13 03:26:24 +00:00
Fix for unit test
This commit is contained in:
parent
e1912d6878
commit
d25c47ccc3
1 changed files with 7 additions and 0 deletions
|
|
@ -1,5 +1,7 @@
|
|||
|
||||
|
||||
import "dart:io";
|
||||
|
||||
import "package:flutter/material.dart";
|
||||
import "package:flutter_overlay_loader/flutter_overlay_loader.dart";
|
||||
import "package:inventree/app_colors.dart";
|
||||
|
|
@ -45,6 +47,11 @@ Widget progressIndicator() {
|
|||
|
||||
void showLoadingOverlay() {
|
||||
|
||||
// Do not show overlay if running unit tests
|
||||
if (Platform.environment.containsKey("FLUTTER_TEST")) {
|
||||
return;
|
||||
}
|
||||
|
||||
BuildContext? context = OneContext.hasContext ? OneContext().context : null;
|
||||
|
||||
if (context == null) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue