improve-performance-of-office-data-import #83

Merged
hsh-michaelhoennig merged 12 commits from improve-performance-of-office-data-import into master 2024-08-05 11:48:34 +02:00
5 changed files with 3 additions and 21 deletions
Showing only changes of commit d179842730 - Show all commits

View File

@ -33,4 +33,4 @@
<RunAsTest>true</RunAsTest>
<method v="2" />
</configuration>
</component>
</component>

1
.run/README.txt Normal file
View File

@ -0,0 +1 @@
Stored run-Configurations for IntelliJ IDEA.

View File

@ -177,7 +177,7 @@ To generate the TOC (Table of Contents), a little bash script from a
Given this is in PATH as `md-toc`, use:
```shell
md-toc <README.md 2 4 | cut -c5-'
md-toc <README.txt 2 4 | cut -c5-'
hsh-michaelhoennig marked this conversation as resolved Outdated

revert

revert
```
To render the Markdown files, especially to watch embedded PlantUML diagrams, you can use one of the following methods:

View File

@ -1117,11 +1117,6 @@ public class ImportHostingAssets extends ImportOfficeData {
.collect(toMap(Map.Entry::getKey, Map.Entry::getValue));
}
@Override
protected void assumeThatWeAreExplicitlyImportingOfficeData() {
assumeThat(false).isTrue();
}
protected static boolean isImportingControlledTestData() {
return MIGRATION_DATA_PATH.equals(TEST_DATA_MIGRATION_DATA_PATH);
}

View File

@ -360,8 +360,6 @@ public class ImportOfficeData extends CsvDataImport {
@Test
@Order(1030)
void importSepaMandates() {
assumeThatWeAreExplicitlyImportingOfficeData();
try (Reader reader = resourceReader(MIGRATION_DATA_PATH + "/office/sepa_mandates.csv")) {
final var lines = readAllLines(reader);
importSepaMandates(justHeader(lines), withoutHeader(lines));
@ -373,7 +371,6 @@ public class ImportOfficeData extends CsvDataImport {
@Test
@Order(1039)
void verifySepaMandates() {
assumeThatWeAreExplicitlyImportingOfficeData();
assumeThatWeAreImportingControlledTestData();
assertThat(toFormattedString(bankAccounts)).isEqualToIgnoringWhitespace("""
@ -403,8 +400,6 @@ public class ImportOfficeData extends CsvDataImport {
@Test
@Order(1040)
void importCoopShares() {
assumeThatWeAreExplicitlyImportingOfficeData();
try (Reader reader = resourceReader(MIGRATION_DATA_PATH + "/office/share_transactions.csv")) {
final var lines = readAllLines(reader);
importCoopShares(justHeader(lines), withoutHeader(lines));
@ -416,7 +411,6 @@ public class ImportOfficeData extends CsvDataImport {
@Test
@Order(1041)
void verifyCoopShares() {
assumeThatWeAreExplicitlyImportingOfficeData();
assumeThatWeAreImportingControlledTestData();
assertThat(toFormattedString(coopShares)).isEqualToIgnoringWhitespace("""
@ -439,8 +433,6 @@ public class ImportOfficeData extends CsvDataImport {
@Test
@Order(1050)
void importCoopAssets() {
assumeThatWeAreExplicitlyImportingOfficeData();
try (Reader reader = resourceReader(MIGRATION_DATA_PATH + "/office/asset_transactions.csv")) {
final var lines = readAllLines(reader);
importCoopAssets(justHeader(lines), withoutHeader(lines));
@ -452,7 +444,6 @@ public class ImportOfficeData extends CsvDataImport {
@Test
@Order(1059)
void verifyCoopAssets() {
assumeThatWeAreExplicitlyImportingOfficeData();
assumeThatWeAreImportingControlledTestData();
assertThat(toFormattedString(coopAssets)).isEqualToIgnoringWhitespace("""
@ -482,7 +473,6 @@ public class ImportOfficeData extends CsvDataImport {
@Test
@Order(1099)
void verifyMemberships() {
assumeThatWeAreExplicitlyImportingOfficeData();
assumeThatWeAreImportingControlledTestData();
assertThat(toFormattedString(memberships)).isEqualToIgnoringWhitespace("""
@ -700,10 +690,6 @@ public class ImportOfficeData extends CsvDataImport {
assertThat(biCount).isGreaterThan(isImportingControlledTestData() ? 5 : 300);
}
protected void assumeThatWeAreExplicitlyImportingOfficeData() {
// not throwing AssumptionException
}
private static boolean isImportingControlledTestData() {
return partners.size() <= MAX_NUMBER_OF_TEST_DATA_PARTNERS;
}