mirror of
https://github.com/HendrikRauh/inventree-app.git
synced 2026-01-13 11:36:24 +00:00
Merge pull request #135 from inventree/unit-testing
Unit testing
(cherry picked from commit d55f594342)
This commit is contained in:
parent
10b435f4fa
commit
cfc9f09b80
35 changed files with 893 additions and 317 deletions
|
|
@ -1,12 +1,12 @@
|
|||
|
||||
import "package:inventree/app_settings.dart";
|
||||
import "package:inventree/widget/snacks.dart";
|
||||
import "package:audioplayers/audioplayers.dart";
|
||||
import "package:flutter/material.dart";
|
||||
import "package:font_awesome_flutter/font_awesome_flutter.dart";
|
||||
import "package:inventree/l10.dart";
|
||||
import "package:inventree/helpers.dart";
|
||||
import "package:one_context/one_context.dart";
|
||||
|
||||
import "package:inventree/l10.dart";
|
||||
import "package:inventree/preferences.dart";
|
||||
import "package:inventree/widget/snacks.dart";
|
||||
|
||||
Future<void> confirmationDialog(String title, String text, {IconData icon = FontAwesomeIcons.questionCircle, String? acceptText, String? rejectText, Function? onAccept, Function? onReject}) async {
|
||||
|
||||
String _accept = acceptText ?? L10().ok;
|
||||
|
|
@ -108,8 +108,7 @@ Future<void> showServerError(String title, String description) async {
|
|||
final bool tones = await InvenTreeSettingsManager().getValue(INV_SOUNDS_SERVER, true) as bool;
|
||||
|
||||
if (tones) {
|
||||
final player = AudioCache();
|
||||
player.play("sounds/server_error.mp3");
|
||||
playAudioFile("sounds/server_error.mp3");
|
||||
}
|
||||
|
||||
showSnackIcon(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue