Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
K-w-e committed May 11, 2024
1 parent fcdd3fc commit 1c815f1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions test/model/recurring_transaction_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@ import 'package:sossoldi/model/base_entity.dart';

void main() {
test('Test Copy Recurring Transaction Amount', () {
DateTime toDateValue = DateTime.utc(2023);
RecurringTransaction t = RecurringTransaction(
id: 2,
fromDate: DateTime.utc(2022),
toDate: DateTime.utc(2023),
toDate: toDateValue,
amount: 14,
note: 'Test Transaction',
recurrency: 'MONTHLY',
Expand All @@ -18,11 +19,11 @@ void main() {
updatedAt: DateTime.utc(2022)
);

RecurringTransaction tCopy = t.copy(id: 10);
RecurringTransaction tCopy = t.copy(id: 10, toDate: toDateValue);

assert(tCopy.id == 10);
assert(tCopy.fromDate == t.fromDate);
assert(tCopy.toDate == t.toDate);
assert(tCopy.toDate == toDateValue);
assert(tCopy.amount == t.amount);
assert(tCopy.note == t.note);
assert(tCopy.recurrency == t.recurrency);
Expand Down

0 comments on commit 1c815f1

Please sign in to comment.