mirror of
https://github.com/inventree/inventree-app.git
synced 2025-04-27 04:56:48 +00:00
Fix for unit test
This commit is contained in:
parent
e1912d6878
commit
d25c47ccc3
@ -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…
x
Reference in New Issue
Block a user