The Battle for Wesnoth  1.19.0-dev
Macros | Functions
test_config.cpp File Reference
#include <boost/test/unit_test.hpp>
#include <boost/test/data/test_case.hpp>
#include <cmath>
#include "config.hpp"
#include "variable_info.hpp"
Include dependency graph for test_config.cpp:

Go to the source code of this file.

Macros

#define GETTEXT_DOMAIN   "wesnoth-test"
 

Functions

 BOOST_AUTO_TEST_CASE (test_config_attribute_value)
 
 BOOST_AUTO_TEST_CASE (test_variable_info)
 
 BOOST_AUTO_TEST_CASE (add_child_EmptyThis_newKey_AppendAndReturnNewEmptyChild)
 
 BOOST_DATA_TEST_CASE (add_child_NonEmptyThis_newOrExistingKey_lOrRValue_AppendAndReturnNewChild, bdata::make({"A", "B", "C"}) *bdata::make< std::string >({"lvalue_ref", "rvalue_ref"}), key, update_ref_kind)
 

Macro Definition Documentation

◆ GETTEXT_DOMAIN

#define GETTEXT_DOMAIN   "wesnoth-test"

Definition at line 16 of file test_config.cpp.

Function Documentation

◆ BOOST_AUTO_TEST_CASE() [1/3]

BOOST_AUTO_TEST_CASE ( add_child_EmptyThis_newKey_AppendAndReturnNewEmptyChild  )

Definition at line 347 of file test_config.cpp.

References config::add_child().

◆ BOOST_AUTO_TEST_CASE() [2/3]

BOOST_AUTO_TEST_CASE ( test_config_attribute_value  )

Definition at line 29 of file test_config.cpp.

References game_config::images::blank, c, and e.

◆ BOOST_AUTO_TEST_CASE() [3/3]

BOOST_AUTO_TEST_CASE ( test_variable_info  )

This is the config: [tag1] [/tag1] [tag1] [tag2] [/tag2] [tag2] [/tag2] [tag2] atribute1 = 88 atribute2 = "value" [/tag2] [/tag1] [tag1] [/tag1]

Definition at line 241 of file test_config.cpp.

References variable_info< V >::as_container(), variable_info< V >::as_scalar(), c, variable_info< V >::exists_as_attribute(), and variable_info< V >::exists_as_container().

◆ BOOST_DATA_TEST_CASE()

BOOST_DATA_TEST_CASE ( add_child_NonEmptyThis_newOrExistingKey_lOrRValue_AppendAndReturnNewChild  ,
bdata::make({"A", "B", "C"}) *bdata::make< std::string >({"lvalue_ref", "rvalue_ref"})  ,
key  ,
update_ref_kind   
)

Definition at line 357 of file test_config.cpp.