@@ -96,12 +96,12 @@ BOOST_AUTO_TEST_CASE(get_bool)
9696 BOOST_TEST_REQUIRE (p_storage);
9797
9898 const auto key = std::filesystem::path{ " hoge" } / " fuga" ;
99- auto value = static_cast < int >( 0 ) ;
99+ auto value = false ;
100100 BOOST_TEST (!tetengo_property_storage_getBool (p_storage, key.string ().c_str (), &value));
101101 }
102102 {
103103 const auto key = std::filesystem::path{ " hoge" } / " fuga" ;
104- auto value = static_cast < int >( 0 ) ;
104+ auto value = false ;
105105 BOOST_TEST (!tetengo_property_storage_getBool (nullptr , key.string ().c_str (), &value));
106106 }
107107 {
@@ -120,7 +120,7 @@ BOOST_AUTO_TEST_CASE(get_bool)
120120 BOOST_SCOPE_EXIT_END;
121121 BOOST_TEST_REQUIRE (p_storage);
122122
123- auto value = static_cast < int >( 0 ) ;
123+ auto value = false ;
124124 BOOST_TEST (!tetengo_property_storage_getBool (p_storage, nullptr , &value));
125125 }
126126 {
@@ -186,8 +186,8 @@ BOOST_AUTO_TEST_CASE(set_bool)
186186 BOOST_TEST_REQUIRE (p_storage);
187187
188188 const auto key = std::filesystem::path{ " hoge" } / " fuga" ;
189- tetengo_property_storage_setBool (p_storage, key.string ().c_str (), 0 );
190- auto value = static_cast < int >( 0 ) ;
189+ tetengo_property_storage_setBool (p_storage, key.string ().c_str (), false );
190+ auto value = false ;
191191 BOOST_TEST (tetengo_property_storage_getBool (p_storage, key.string ().c_str (), &value));
192192 BOOST_TEST (!value);
193193 }
@@ -208,8 +208,8 @@ BOOST_AUTO_TEST_CASE(set_bool)
208208 BOOST_TEST_REQUIRE (p_storage);
209209
210210 const auto key = std::filesystem::path{ " hoge" } / " fuga" ;
211- tetengo_property_storage_setBool (p_storage, key.string ().c_str (), 1 );
212- auto value = static_cast < int >( 0 ) ;
211+ tetengo_property_storage_setBool (p_storage, key.string ().c_str (), true );
212+ auto value = false ;
213213 BOOST_TEST (tetengo_property_storage_getBool (p_storage, key.string ().c_str (), &value));
214214 BOOST_TEST (value);
215215 }
@@ -230,8 +230,8 @@ BOOST_AUTO_TEST_CASE(set_bool)
230230 BOOST_TEST_REQUIRE (p_storage);
231231
232232 const auto key = std::filesystem::path{ " hoge" } / " fuga" ;
233- tetengo_property_storage_setBool (nullptr , key.string ().c_str (), 1 );
234- auto value = static_cast < int >( 0 ) ;
233+ tetengo_property_storage_setBool (nullptr , key.string ().c_str (), true );
234+ auto value = false ;
235235 BOOST_TEST (!tetengo_property_storage_getBool (p_storage, key.string ().c_str (), &value));
236236 }
237237 {
@@ -251,8 +251,8 @@ BOOST_AUTO_TEST_CASE(set_bool)
251251 BOOST_TEST_REQUIRE (p_storage);
252252
253253 const auto key = std::filesystem::path{ " hoge" } / " fuga" ;
254- tetengo_property_storage_setBool (p_storage, nullptr , 1 );
255- auto value = static_cast < int >( 0 ) ;
254+ tetengo_property_storage_setBool (p_storage, nullptr , true );
255+ auto value = false ;
256256 BOOST_TEST (!tetengo_property_storage_getBool (p_storage, key.string ().c_str (), &value));
257257 }
258258}
0 commit comments