Skip to content

Commit

Permalink
Fix lint issues
Browse files Browse the repository at this point in the history
  • Loading branch information
oruebel committed Aug 9, 2024
1 parent 58b515c commit cbc0631
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/hdf5/HDF5IO.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ Status checkStatus(int status)

Status HDF5IO::flush()
{
int status = H5Fflush(this->file->getId(), H5F_SCOPE_GLOBAL);
int status = H5Fflush(this->file->getId(), H5F_SCOPE_GLOBAL);
return checkStatus(status);
}

Expand Down
2 changes: 1 addition & 1 deletion src/hdf5/HDF5IO.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ class HDF5IO : public BaseIO
* @brief Flush data to disk
* @return The status of the flush operation.
*/
Status flush() override;
Status flush() override;

/**
* @brief Creates an attribute at a given location in the file.
Expand Down
17 changes: 10 additions & 7 deletions tests/testHDF5IO_docs_examples.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
#include <future>
#include <iostream>
#include <memory>
#include <vector>
#include <numeric>
#include <vector>

#include <catch2/catch_test_macros.hpp>

Expand All @@ -28,15 +28,17 @@ TEST_CASE("SWMRmodeExamples", "[hdf5io]")

// add a dataset
std::vector<int> testData(10000);
std::iota(testData.begin(), testData.end(), 1); // Initalize the testData to 0, 1, 2, ... 10000
std::iota(testData.begin(),
testData.end(),
1); // Initalize the testData to 0, 1, 2, ... 10000

Check failure on line 33 in tests/testHDF5IO_docs_examples.cpp

View workflow job for this annotation

GitHub Actions / Check for spelling errors

Initalize ==> Initialize
std::string dataPath = "/data";
SizeType numBlocks = 10; // write 10 chunks of
SizeType numBlocks = 10; // write 10 chunks of
SizeType numSamples = testData.size();
std::unique_ptr<BaseRecordingData> dataset = hdf5io->createArrayDataSet(
BaseDataType::I32, // type
SizeArray {0}, // size. Initial size of the dataset
SizeArray {1000}, // chunking. Size of a data chunk
dataPath); // path. Path to the dataset in the HDF5 file
SizeArray {0}, // size. Initial size of the dataset
SizeArray {1000}, // chunking. Size of a data chunk
dataPath); // path. Path to the dataset in the HDF5 file

// Start recording. Starting the recording places the HDF5 file in SWMR mode
Status status = hdf5io->startRecording();
Expand All @@ -56,7 +58,8 @@ TEST_CASE("SWMRmodeExamples", "[hdf5io]")
REQUIRE(status == Status::Success);
}

// stop recording. In SWMR mode the file is now closed and recording cannot be restarted
// stop recording. In SWMR mode the file is now closed and recording cannot
// be restarted
status = hdf5io->stopRecording();
REQUIRE(hdf5io->isOpen() == false);
REQUIRE(hdf5io->startRecording() == Status::Failure);
Expand Down

0 comments on commit cbc0631

Please sign in to comment.