unit-tests-live-lr200.cpp
Go to the documentation of this file.
1 // License: Apache 2.0. See LICENSE file in root directory.
2 // Copyright(c) 2015 Intel Corporation. All Rights Reserved.
3 
5 // This set of tests is valid only for the R200 camera //
7 
8 #if !defined(MAKEFILE) || ( defined(LIVE_TEST) && ( defined(LR200_TEST) || defined(ZR300_TEST) ) )
9 
11 
12 #include <climits>
13 #include <sstream>
14 
15 TEST_CASE("Streams COLOR HD 1920X1080 Raw16 30FPS", "[live] [lr200] [one-camera]")
16 {
17  // Require only one device to be plugged in
19  const int device_count = rs_get_device_count(ctx, require_no_error());
20  REQUIRE(device_count == 1);
21 
23  REQUIRE(dev != nullptr);
24  REQUIRE(std::any_of(ds_names.begin(), ds_names.end(), [&](std::string const& s) {return s == rs_get_device_name(dev, require_no_error()); }));
25 
27 }
28 
29 //TEST_CASE("LR200 Testing RGB Exposure values", "[live] [DS-device] [one-camera]")
30 //{
31 // // the range is [-8:1:-4]
32 // test_ds_device_option(RS_OPTION_COLOR_EXPOSURE, { -8, -7, -6, -5, -4 }, {}, BEFORE_START_DEVICE | AFTER_START_DEVICE);
33 //}
34 
35 #endif /* !defined(MAKEFILE) || ( defined(LIVE_TEST) && ( defined(LR200_TEST) || defined(ZR300_TEST) ) ) */
int rs_get_device_count(const rs_context *context, rs_error **error)
Determines number of connected devices.
Definition: rs.cpp:113
GLsizei const GLchar *const * string
Definition: glext.h:683
#define REQUIRE(expr)
Definition: catch.hpp:9333
const char * rs_get_device_name(const rs_device *device, rs_error **error)
Retrieves human-readable device model string.
Definition: rs.cpp:128
void test_ds_device_streaming(std::initializer_list< stream_mode > modes)
TEST_CASE("Streams COLOR HD 1920X1080 Raw16 30FPS","[live] [lr200] [one-camera]")
auto ctx
GLdouble s
Definition: glext.h:231
rs_device * dev
rs_device * rs_get_device(rs_context *context, int index, rs_error **error)
Retrieves connected device by index.
Definition: rs.cpp:120
static const std::vector< std::string > ds_names


librealsense
Author(s): Sergey Dorodnicov , Mark Horn , Reagan Lopez
autogenerated on Fri Mar 13 2020 03:16:18