mirror of
https://github.com/paulscherrerinstitute/sf_daq_buffer.git
synced 2026-05-01 01:22:23 +02:00
Adjust tests to config change
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
#include "FastH5Writer.hpp"
|
||||
#include "gtest/gtest.h"
|
||||
|
||||
using namespace core_buffer;
|
||||
|
||||
TEST(FastH5Writer, basic_interaction)
|
||||
{
|
||||
auto root_folder = ".";
|
||||
@@ -16,7 +18,7 @@ TEST(FastH5Writer, basic_interaction)
|
||||
metadata.n_recv_packets = 128;
|
||||
|
||||
FastH5Writer writer(
|
||||
BufferUtils::FILE_MOD, 512, 1024, device_name, root_folder);
|
||||
core_buffer::FILE_MOD, 512, 1024, device_name, root_folder);
|
||||
|
||||
writer.add_scalar_metadata<uint64_t>("pulse_id");
|
||||
writer.add_scalar_metadata<uint64_t>("frame_id");
|
||||
@@ -99,7 +101,7 @@ TEST(FastH5Writer, SWMR)
|
||||
}
|
||||
|
||||
FastH5Writer writer(
|
||||
BufferUtils::FILE_MOD, 512, 1024, device_name, root_folder);
|
||||
FILE_MOD, MODULE_Y_SIZE, MODULE_X_SIZE, device_name, root_folder);
|
||||
writer.add_scalar_metadata<uint64_t>("pulse_id");
|
||||
writer.set_pulse_id(0);
|
||||
|
||||
|
||||
@@ -1,12 +1,13 @@
|
||||
#include "gtest/gtest.h"
|
||||
#include "BufferUtils.hpp"
|
||||
#include "buffer_config.hpp"
|
||||
|
||||
using namespace std;
|
||||
|
||||
TEST(BufferUtils, get_filename)
|
||||
{
|
||||
auto expected_file = "/root/device-1/12300000/12345000" +
|
||||
BufferUtils::FILE_EXTENSION;
|
||||
core_buffer::FILE_EXTENSION;
|
||||
|
||||
auto root_folder = "/root";
|
||||
auto device_name = "device-1";
|
||||
|
||||
Reference in New Issue
Block a user