Skip to content

Commit 6b76a70

Browse files
committed
Fix #3
In the tests, don't try to read the series with listSeries after already having fully drained it
1 parent 543d894 commit 6b76a70

1 file changed

Lines changed: 13 additions & 21 deletions

File tree

test/SerialIOTest.cpp

Lines changed: 13 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -5085,35 +5085,27 @@ void append_mode(
50855085
++counter;
50865086
}
50875087
REQUIRE( counter == 5 );
5088+
// Cannot do listSeries here because the Series is already drained
5089+
// @todo better error message if attempting this
5090+
// helper::listSeries( read );
50885091
}
50895092
else
50905093
{
50915094
REQUIRE( read.iterations.size() == 5 );
5095+
/*
5096+
* Roadmap: for now, reading this should work by ignoring the last
5097+
* duplicate iteration.
5098+
* After merging https://github.com/openPMD/openPMD-api/pull/949, we
5099+
* should see both instances when reading.
5100+
* Final goal: Read only the last instance.
5101+
*/
5102+
helper::listSeries( read );
50925103
}
5093-
/*
5094-
* Roadmap: for now, reading this should work by ignoring the last
5095-
* duplicate iteration.
5096-
* After merging https://github.com/openPMD/openPMD-api/pull/949, we
5097-
* should see both instances when reading.
5098-
* Final goal: Read only the last instance.
5099-
*/
5100-
helper::listSeries( read );
51015104
}
51025105
}
51035106

51045107
TEST_CASE( "append_mode", "[serial]" )
51055108
{
5106-
// append_mode( "bp", false, R"END(
5107-
// {
5108-
// "adios2":
5109-
// {
5110-
// "schema": 20210209,
5111-
// "engine":
5112-
// {
5113-
// "usesteps" : true
5114-
// }
5115-
// }
5116-
// })END");
51175109
for( auto const & t : testedFileExtensions() )
51185110
{
51195111
if( t == "bp" )
@@ -5142,8 +5134,8 @@ TEST_CASE( "append_mode", "[serial]" )
51425134
})END";
51435135
append_mode( t, false, jsonConfigOld );
51445136
append_mode( t, false, jsonConfigNew );
5145-
//append_mode( t, true, jsonConfigOld );
5146-
//append_mode( t, true, jsonConfigNew );
5137+
append_mode( t, true, jsonConfigOld );
5138+
append_mode( t, true, jsonConfigNew );
51475139
}
51485140
else
51495141
{

0 commit comments

Comments
 (0)