#include <gtest/gtest.h>
#include "interop/io/metric_stream.h"
#include "interop/io/metric_file_stream.h"
#include "src/tests/interop/metrics/inc/metric_format_fixtures.h"
Classes | |
struct | metric_stream_error_test< TestSetup > |
Functions | |
TYPED_TEST_CASE_P (metric_stream_error_test) | |
TYPED_TEST_P (metric_stream_error_test, test_hardcoded_bad_format_exception) | |
TYPED_TEST_P (metric_stream_error_test, test_hardcoded_incomplete_file_exception) | |
TYPED_TEST_P (metric_stream_error_test, test_hardcoded_incomplete_file_exception_last_metric) | |
TYPED_TEST_P (metric_stream_error_test, test_hardcoded_incorrect_record_size) | |
TYPED_TEST_P (metric_stream_error_test, test_hardcoded_file_not_found) | |
TYPED_TEST_P (metric_stream_error_test, test_hardcoded_read) | |
TEST (metric_stream_error_test, image_metric_out_of_bounds) | |
REGISTER_TYPED_TEST_CASE_P (metric_stream_error_test, test_hardcoded_bad_format_exception, test_hardcoded_incomplete_file_exception, test_hardcoded_incomplete_file_exception_last_metric, test_hardcoded_incorrect_record_size, test_hardcoded_file_not_found, test_hardcoded_read) | |
INSTANTIATE_TYPED_TEST_CASE_P (Public, metric_stream_error_test, PublicFormats) | |
Detailed Description
Unit tests for the metric stream error coniditions
- Date
- 11/20/16
- Version
- 1.0
- Copyright
- GNU Public License.
Function Documentation
INSTANTIATE_TYPED_TEST_CASE_P | ( | Public | , |
metric_stream_error_test | , | ||
PublicFormats | |||
) |
REGISTER_TYPED_TEST_CASE_P | ( | metric_stream_error_test | , |
test_hardcoded_bad_format_exception | , | ||
test_hardcoded_incomplete_file_exception | , | ||
test_hardcoded_incomplete_file_exception_last_metric | , | ||
test_hardcoded_incorrect_record_size | , | ||
test_hardcoded_file_not_found | , | ||
test_hardcoded_read | |||
) |
TEST | ( | metric_stream_error_test | , |
image_metric_out_of_bounds | |||
) |
Confirm that the InterOp writer will not access memory out of bounds
TYPED_TEST_CASE_P | ( | metric_stream_error_test | ) |
TYPED_TEST_P | ( | metric_stream_error_test | , |
test_hardcoded_bad_format_exception | |||
) |
Confirm bad_format_exception is thrown when version is unsupported
TYPED_TEST_P | ( | metric_stream_error_test | , |
test_hardcoded_incomplete_file_exception | |||
) |
Confirm incomplete_file_exception is thrown for a small partial record
TYPED_TEST_P | ( | metric_stream_error_test | , |
test_hardcoded_incomplete_file_exception_last_metric | |||
) |
Confirm incomplete_file_exception is thrown for a mostly complete file
TYPED_TEST_P | ( | metric_stream_error_test | , |
test_hardcoded_incorrect_record_size | |||
) |
Confirm bad_format_exception is thrown when record size is incorrect
TYPED_TEST_P | ( | metric_stream_error_test | , |
test_hardcoded_file_not_found | |||
) |
Confirm file_not_found_exception is thrown when a file is not found
TYPED_TEST_P | ( | metric_stream_error_test | , |
test_hardcoded_read | |||
) |
Confirm reading from good data does not throw an exception