swt-importer тест на RDC_KS_DF-20
This commit is contained in:
parent
3fbb5931df
commit
9f988d34c0
3 changed files with 33 additions and 1 deletions
|
|
@ -19,7 +19,7 @@ public class ImportSWTServiceTest {
|
|||
public ImportSWTServiceSettings settings(){
|
||||
ImportSWTServiceSettings settings = new ImportSWTServiceSettings();
|
||||
Common common = new Common();
|
||||
common.setEncodingSource("cp866");
|
||||
common.setEncodingSource("windows-1251"); // cp866 или windows-1251
|
||||
settings.setCommon(common);
|
||||
return settings;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -121,4 +121,20 @@ class ImportToDBTest {
|
|||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void process_20_1() throws IOException {
|
||||
ETable eTable = ETable.S_DF_20;
|
||||
{
|
||||
File swtFile = new File("src/test/resources/input", "RDC_KS_DF-20_230915112704000.txt");
|
||||
ResultContainer resultContainer = createNewTask(eTable, swtFile);
|
||||
resultContainer.setSwtSource(Files.readAllBytes(Paths.get(swtFile.getAbsolutePath())));
|
||||
|
||||
Imdg<SDf20> df20Imdg = imdgProvider.getImdg(IMDGDistributedNames.Map_SDf20, SDf20.class);
|
||||
((ImdgHazelcast)df20Imdg).clear();
|
||||
importToDB.process(resultContainer);
|
||||
Collection<SDf20> values = df20Imdg.getAllValues();
|
||||
Assertions.assertEquals(1, values.size());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
To:SPCE
|
||||
From:CSO
|
||||
Type:512
|
||||
Date/Time:20230929/1057
|
||||
:20:SPCEX_20230915Q3-601
|
||||
:21:NONREF2121
|
||||
:35B:ISIN SU26238RMFS4:Ìèíôèí Ðîññèè:îáëèãàöèè
|
||||
:60A:SHS0,
|
||||
:83D:700988887ZT0:Áàíê Ðîññèè
|
||||
:20C:Ïîðó÷. SPCEX_20230915_1
|
||||
:35A:SHS120000,
|
||||
:23:850
|
||||
:66A:RECFREE
|
||||
:87D:
|
||||
:30:20231109
|
||||
:62A:SHS120000,
|
||||
Loading…
Add table
Reference in a new issue