Closed
Description
Version
2022.8.233
Description
UTBot adds unused constant to the test
static const float utbot_abs_error = 1e-6;
Generate code for following function
char a_or_b(char a, char b) {
if (a == 'a')
return a;
else
return b;
}
Result is
#include "snippet_dot_c_test.h"
#include "gtest/gtest.h"
namespace UTBot {
static const float utbot_abs_error = 1e-6;
#pragma region regression
TEST(regression, a_or_b_test_1)
{
char actual = a_or_b('h', 'c');
EXPECT_EQ('c', actual);
}
TEST(regression, a_or_b_test_2)
{
char actual = a_or_b('a', 'c');
EXPECT_EQ('a', actual);
}
#pragma endregion
}
generated constant utbot_abs_error
is unused and seems unecessary.
Metadata
Metadata
Assignees
Type
Projects
Status
Done