Currently job artifacts in CI/CD pipelines on LRZ GitLab never expire. Starting from Wed 26.1.2022 the default expiration time will be 30 days (GitLab default). Currently existing artifacts in already completed jobs will not be affected by the change. The latest artifacts for all jobs in the latest successful pipelines will be kept. More information:

Commit 571bb014 authored by Hossain Mahmud's avatar Hossain Mahmud Committed by Christian Schulte zu Berge
Browse files

added ImageSeries tests

parent ab691100
......@@ -78,5 +78,4 @@ namespace campvis {
return _images[index];
\ No newline at end of file
// include gtest library
#include "gtest/gtest.h"
// include(s) for class to be tested
#include "core/datastructures/imageseries.h"
// additional includes
#include "core/datastructures/imagedata.h"
class ImageSeriesTest : public testing::Test {
ImageSeriesTest() {
_image = new campvis::ImageData(2, tgt::svec3(1,2,3), 4);
_dh = campvis::DataHandle(_image);
~ImageSeriesTest() {
delete _image;
// If the constructor and destructor are not enough for setting up
// and cleaning up each test, you can define the following two methods
virtual void SetUp() {
virtual void TearDown() {
campvis::ImageSeries _imgSeries1, _imgSeries2, _imgSeries3;
campvis::ImageData* _image;
campvis::DataHandle _dh;
TEST_F(ImageSeriesTest, getNumImageTest) {
EXPECT_EQ(0, _imgSeries1.getNumImages());
EXPECT_EQ(1, _imgSeries2.getNumImages());
EXPECT_EQ(1, _imgSeries3.getNumImages());
TEST_F(ImageSeriesTest, addImageTest) {
EXPECT_EQ(2, _imgSeries3.getNumImages());
TEST_F(ImageSeriesTest, getImageTest) {
//EXPECT_EQ(_dh.getData(), &_imgSeries2.getImage(_imgSeries2.getNumImages()-1).getData());
EXPECT_EQ(_dh.getTimestamp(), _imgSeries2.getImage(_imgSeries2.getNumImages()-1).getTimestamp());
TEST_F(ImageSeriesTest, getLocalMemoryFootprintTest) {
TEST_F(ImageSeriesTest, getVideoMemoryFootprintTest) {
TEST_F(ImageSeriesTest, cloneTest) {
campvis::ImageSeries* tempSeries = _imgSeries2.clone();
EXPECT_EQ(_imgSeries2.getNumImages(), tempSeries->getNumImages());
EXPECT_EQ(_imgSeries2.getLocalMemoryFootprint(), tempSeries->getLocalMemoryFootprint());
EXPECT_EQ(_imgSeries2.getVideoMemoryFootprint(), tempSeries->getVideoMemoryFootprint());
EXPECT_EQ(_imgSeries2.getImage(_imgSeries2.getNumImages()-1).getTimestamp(), tempSeries->getImage(tempSeries->getNumImages()-1).getTimestamp());
delete tempSeries;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment