Skip to content

Commit

Permalink
Remove unsanitized input test data from copy gtests (#14600)
Browse files Browse the repository at this point in the history
Removes unsanitized rows from input data in gtests for COPYING_TEST.
This fixes some errors found in #14559

Authors:
  - David Wendt (https://github.com/davidwendt)

Approvers:
  - Bradley Dice (https://github.com/bdice)
  - Karthikeyan (https://github.com/karthikeyann)

URL: #14600
  • Loading branch information
davidwendt authored Dec 12, 2023
1 parent fcaebeb commit 1c6f80d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 14 deletions.
16 changes: 3 additions & 13 deletions cpp/tests/copying/copy_if_else_nested_tests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -386,22 +386,12 @@ TYPED_TEST(TypedCopyIfElseNestedTest, ScalarListBothInvalid)
using bools = cudf::test::fixed_width_column_wrapper<bool, int32_t>;
using lcw = cudf::test::lists_column_wrapper<T, int32_t>;

auto lhs_scalar = cudf::list_scalar{ints{33, 33, 33}, false};
auto rhs_scalar = cudf::list_scalar{ints{22, 22}, false};
auto lhs_scalar = cudf::list_scalar{ints{}, false};
auto rhs_scalar = cudf::list_scalar{ints{}, false};

auto selector_column = bools{1, 1, 0, 1, 1, 0, 1}.release();

auto expected = lcw{{
{-33, -33, -33},
{-33, -33, -33},
{-22, -22},
{-33, -33, -33},
{-33, -33, -33},
{-22, -22},
{-33, -33, -33},
},
all_nulls()}
.release();
auto expected = lcw{{lcw{}, lcw{}, lcw{}, lcw{}, lcw{}, lcw{}, lcw{}}, all_nulls()}.release();

auto result = cudf::copy_if_else(lhs_scalar, rhs_scalar, selector_column->view());

Expand Down
1 change: 0 additions & 1 deletion cpp/tests/copying/purge_nonempty_nulls_tests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ struct PurgeNonEmptyNullsTest : public cudf::test::BaseFixture {
void test_purge(cudf::column_view const& unpurged)
{
auto const purged = cudf::purge_nonempty_nulls(unpurged);
CUDF_TEST_EXPECT_COLUMNS_EQUIVALENT(unpurged, *purged);
EXPECT_FALSE(cudf::has_nonempty_nulls(*purged));
}
};
Expand Down

0 comments on commit 1c6f80d

Please sign in to comment.