Various stuff

build-war maven profile now builds a tomcat parallel deployment
compatible war file. Fix test data and integrations tests. Add a bunch
of accounts to the init data.
This commit is contained in:
2019-03-16 22:27:02 +01:00
parent aa92718e74
commit 57643f5b5b
4 changed files with 59 additions and 5 deletions

View File

@@ -13,7 +13,7 @@
<groupId>de.77zzcx7</groupId>
<artifactId>financer</artifactId>
<version>1.0-SNAPSHOT</version>
<version>1-SNAPSHOT</version>
<packaging>${packaging.type}</packaging>
<name>financer</name>
@@ -160,6 +160,9 @@
<properties>
<packaging.type>war</packaging.type>
</properties>
<build>
<finalName>financer##${project.version}</finalName>
</build>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>

View File

@@ -13,3 +13,54 @@ VALUES ('accounts.start', 'START', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.rent', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.fvs', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.car', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.gas', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.alimony', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.electricitywater', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.mobile', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.internet', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.legalinsurance', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.netflix', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.hetzner', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.fees', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.food', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.foodexternal', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.child', 'EXPENSE', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.creditcard', 'LIABILITY', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.studentloan', 'LIABILITY', 'OPEN', 0);
INSERT INTO account ("key", type, status, current_balance)
VALUES ('accounts.bed', 'LIABILITY', 'OPEN', 0);

View File

@@ -44,6 +44,6 @@ public class AccountController_getAllIntegrationTest {
final List<Account> allAccounts = this.objectMapper
.readValue(mvcResult.getResponse().getContentAsByteArray(), new TypeReference<List<Account>>() {});
Assert.assertEquals(6, allAccounts.size());
Assert.assertEquals(23, allAccounts.size());
}
}

View File

@@ -4,7 +4,7 @@ VALUES ('accounts.convenience', 'EXPENSE', 'OPEN', 0);
--Recurring transactions
INSERT INTO recurring_transaction (from_account_id, to_account_id, description, amount, interval_type, first_occurrence, holiday_weekend_type)
VALUES (2, 1, 'Pay', 250000, 'MONTHLY', '2019-01-15', 'NEXT_WORKDAY');
VALUES ((SELECT ID FROM account WHERE "key" = 'accounts.income'), (SELECT ID FROM account WHERE "key" = 'accounts.checkaccount'), 'Pay', 250000, 'MONTHLY', '2019-01-15', 'NEXT_WORKDAY');
INSERT INTO recurring_transaction (from_account_id, to_account_id, description, amount, interval_type, first_occurrence, holiday_weekend_type)
VALUES (3, 5, 'Pretzel', 170, 'DAILY', '2019-02-20', 'SAME_DAY');
VALUES ((SELECT ID FROM account WHERE "key" = 'accounts.cash'), (SELECT ID FROM account WHERE "key" = 'accounts.convenience'), 'Pretzel', 170, 'DAILY', '2019-02-20', 'SAME_DAY');