-// Copyright (C) 2010-2018 Internet Systems Consortium, Inc. ("ISC")
+// Copyright (C) 2010-2019 Internet Systems Consortium, Inc. ("ISC")
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
/// negative means outbound and perhaps looping forever).
/// @return a pointer to a fresh copy
/// @throw raises a BadValue is a null pointer occurs.
-ElementPtr copy(ConstElementPtr from, int level = 100);
+ElementPtr copy(ConstElementPtr from, int level = 100);
/// @brief Compares the data with other using unordered lists
///
/// @param scope specified parameter will be extracted from this scope
/// @param name name of the parameter
/// @return a double value of the parameter
- /// @throw DhcpConfigError if the parameter is not there or is not
+ /// @throw DhcpConfigError if the parameter is not there or is not
/// an Element::real
- static double getDouble(const ConstElementPtr& scope,
+ static double getDouble(const ConstElementPtr& scope,
const std::string& name);
protected:
-// Copyright (C) 2009-2018 Internet Systems Consortium, Inc. ("ISC")
+// Copyright (C) 2009-2019 Internet Systems Consortium, Inc. ("ISC")
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
EXPECT_THROW(parseAnswer(rcode, el("{ \"result\": [ 0 ] }")), CtrlChannelError);
EXPECT_THROW(parseAnswer(rcode, el("{ \"result\": [ 1 ] }")), CtrlChannelError);
EXPECT_THROW(parseAnswer(rcode, el("{ \"result\": [ 1, 1 ] }")), CtrlChannelError);
-
+
answer = el("{ \"result\": 0 }");
arg = parseAnswer(rcode, answer);
EXPECT_EQ(0, rcode);
TEST_F(SimpleParserTest, getDouble) {
SimpleParserClassTest parser;
- std::string json =
+ std::string json =
"{\n"
" \"string\" : \"12.3\",\n"
" \"bool\" : true, \n"