-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7 from Samoy/dev
And unit tests
- Loading branch information
Showing
40 changed files
with
1,635 additions
and
609 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,13 @@ jobs: | |
flutter-version: ${{ env.FLUTTER_VERSION }} | ||
cache: true | ||
|
||
- name: Install Tools | ||
uses: awalsh128/cache-apt-pkgs-action@latest | ||
with: | ||
packages: clang cmake git ninja-build pkg-config libgtk-3-dev liblzma-dev libstdc++-12-dev | ||
version: 1.0 | ||
if: runner.os == 'Linux' | ||
|
||
- name: Install dependencies | ||
id: install | ||
run: flutter pub get | ||
|
@@ -41,8 +48,9 @@ jobs: | |
run: dart analyze --fatal-infos | ||
if: always() && steps.install.outcome == 'success' | ||
|
||
- name: Run tests | ||
- name: Run unit tests | ||
run: flutter test --coverage --reporter github | ||
|
||
- name: Upload coverage reports to Codecov | ||
uses: codecov/[email protected] | ||
with: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,3 +46,6 @@ app.*.map.json | |
|
||
# Release | ||
/release | ||
|
||
# Test Coverage | ||
coverage/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
class SnackBarUtils { | ||
static ScaffoldFeatureController<SnackBar, SnackBarClosedReason> showSnackBar( | ||
BuildContext context, | ||
String message, { | ||
Duration duration = const Duration(seconds: 2), | ||
}) { | ||
return ScaffoldMessenger.of(context).showSnackBar( | ||
SnackBar( | ||
content: Text(message), | ||
duration: duration, | ||
), | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
class ImagePathModel extends ChangeNotifier { | ||
String _imagePath = ""; | ||
|
||
String get imagePath => _imagePath; | ||
|
||
set imagePath(String value) { | ||
_imagePath = value; | ||
notifyListeners(); | ||
} | ||
|
||
void clearImage() { | ||
_imagePath = ""; | ||
notifyListeners(); | ||
} | ||
} |
Oops, something went wrong.