MCPcopy Create free account
hub / github.com/apache/arrow / TestCustomNulls

Method TestCustomNulls

cpp/src/arrow/csv/converter_test.cc:205–221  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

203 }
204
205 void TestCustomNulls() {
206 auto type = this->type();
207 auto options = ConvertOptions::Defaults();
208 options.null_values = {"xxx", "zzz"};
209 AssertConversion<T, std::string>(type, {"ab,N/A\n", "xxx,\"zzz\"\n"},
210 {{"ab", "xxx"}, {"N/A", "zzz"}},
211 {{true, true}, {true, true}}, options);
212
213 options.strings_can_be_null = true;
214 AssertConversion<T, std::string>(type, {"ab,N/A\n", "xxx,\"zzz\"\n"},
215 {{"ab", ""}, {"N/A", ""}},
216 {{true, false}, {true, false}}, options);
217 options.quoted_strings_can_be_null = false;
218 AssertConversion<T, std::string>(type, {"ab,N/A\n", "xxx,\"zzz\"\n"},
219 {{"ab", ""}, {"N/A", "zzz"}},
220 {{true, false}, {true, true}}, options);
221 }
222};
223
224template <typename T>

Callers 1

TYPED_TESTFunction · 0.80

Calls 2

typeMethod · 0.95
DefaultsFunction · 0.50

Tested by

no test coverage detected