A flutter app project created for a certain company software engineering test.
- Flutter version:
3.24.0
- Flutter manager used: puro
-
Install the required dependencies:
npm install json-server
-
Start the fake API server:
npx json-server db.json
-
The fake API server will start running on
http://localhost:3000
.
-
Install the required dependencies:
flutter pub get
-
Start the app:
flutter run --dart-define=API_URL=http://localhost:3000
This will launch the app on the connected device or emulator. The
API_URL
environment variable is used to specify the URL of the fake API server. Change the value ofAPI_URL
if the fake API server is running on a different URL.If you are using android emulator, you may want to use
10.0.2.2:3000
as theAPI_URL
instead oflocalhost:3000
. -
Once inside the app. You may send money to the ff users:
Name ID John Doe 123 Jane Doe 456 Government 789 Note that the the current user is John Doe with the ID of 123. You may change the current user by going to the
MockUserDataSource
class.
-
Wallet Balance
- View the current balance in the wallet.
- Show 500.00php as user's current balance.
- Ability to show and hide the balance
-
Send Money
- Input field that accepts numbers.
- Bottom sheet on success/error indicator on transaction response
- Send money to another user by entering the amount
-
Transaction History
- View the transaction history of the wallet
- Show details like the amount send and timestamp
- Unit Test
- Uses fake API https://jsonplaceholder.typicode.com/
- Clean architecture with flutter_bloc
- Uses flutter
To run the tests, use the following command:
flutter test