openMSX
Functions | Variables
TclObject_test.cc File Reference
#include "catch.hpp"
#include "Interpreter.hh"
#include "TclObject.hh"
#include "view.hh"
#include <cstdint>
#include <cstring>
#include <iterator>
#include <string>
Include dependency graph for TclObject_test.cc:

Go to the source code of this file.

Functions

 TEST_CASE ("TclObject, constructors")
 
 TEST_CASE ("TclObject, assignment")
 
 TEST_CASE ("TclObject, operator=")
 
 TEST_CASE ("TclObject, addListElement")
 
 TEST_CASE ("TclObject, addListElements")
 
t addDictKeyValue ("one", 1)
 
 CHECK (t.getDictValue(interp, "one").getInt(interp)==1)
 
 CHECK (t.getDictValue(interp, "two").getString()=="")
 
 CHECK (t.getDictValue(interp, "three").getString()=="")
 
t addDictKeyValues ("two", 2, "three", 3.14)
 
 CHECK (t.getDictValue(interp, "two").getInt(interp)==2)
 
 CHECK (t.getDictValue(interp, "three").getDouble(interp)==3.14)
 
t addDictKeyValues ("four", false, "one", "een")
 
 CHECK (t.getDictValue(interp, "one").getString()=="een")
 
 CHECK (t.getDictValue(interp, "four").getBoolean(interp)==false)
 
 TEST_CASE ("TclObject, getXXX")
 
 TEST_CASE ("TclObject, getDictValue")
 
 TEST_CASE ("TclObject, STL interface on Tcl list")
 
 TEST_CASE ("TclObject, evalBool")
 
 TEST_CASE ("TclObject, executeCommand")
 
 TEST_CASE ("TclObject, operator==, operator!=")
 

Variables

TclObject t
 

Function Documentation

◆ addDictKeyValue()

t addDictKeyValue ( "one"  ,
 
)

◆ addDictKeyValues() [1/2]

t addDictKeyValues ( "four"  ,
false  ,
"one"  ,
"een"   
)

◆ addDictKeyValues() [2/2]

t addDictKeyValues ( "two"  ,
,
"three"  ,
3.  14 
)

◆ CHECK() [1/7]

CHECK ( t.  getDictValueinterp, "four").getBoolean(interp = =false)

◆ CHECK() [2/7]

CHECK ( t.  getDictValueinterp, "one").getInt(interp = =1)

Referenced by TEST_CASE().

◆ CHECK() [3/7]

CHECK ( t.  getDictValueinterp, "one").getString( = ="een")

◆ CHECK() [4/7]

CHECK ( t.  getDictValueinterp, "three").getDouble(interp = =3.14)

◆ CHECK() [5/7]

CHECK ( t.  getDictValueinterp, "three").getString( = ="")

◆ CHECK() [6/7]

CHECK ( t.  getDictValueinterp, "two").getInt(interp = =2)

◆ CHECK() [7/7]

CHECK ( t.  getDictValueinterp, "two").getString( = ="")

◆ TEST_CASE() [1/11]

TEST_CASE ( TclObject,
addListElement"   
)

◆ TEST_CASE() [2/11]

TEST_CASE ( TclObject,
addListElements"   
)

◆ TEST_CASE() [3/11]

TEST_CASE ( TclObject,
assignment"   
)

Definition at line 88 of file TclObject_test.cc.

References CHECK(), and openmsx::TclObject::getString().

◆ TEST_CASE() [4/11]

TEST_CASE ( TclObject,
constructors"   
)

◆ TEST_CASE() [5/11]

TEST_CASE ( TclObject,
evalBool"   
)

Definition at line 376 of file TclObject_test.cc.

References CHECK().

◆ TEST_CASE() [6/11]

TEST_CASE ( TclObject,
executeCommand"   
)

◆ TEST_CASE() [7/11]

TEST_CASE ( TclObject,
getDictValue"   
)

Definition at line 324 of file TclObject_test.cc.

References CHECK(), openmsx::TclObject::getDictValue(), and t.

◆ TEST_CASE() [8/11]

TEST_CASE ( TclObject,
getXXX"   
)

◆ TEST_CASE() [9/11]

TEST_CASE ( TclObject)

◆ TEST_CASE() [10/11]

TEST_CASE ( TclObject,
operator  = = 
)

Definition at line 397 of file TclObject_test.cc.

References CHECK().

◆ TEST_CASE() [11/11]

TEST_CASE ( TclObject,
STL interface on Tcl list"   
)

Variable Documentation

◆ t

Initial value:
{
Interpreter interp

Definition at line 266 of file TclObject_test.cc.

Referenced by cstd::abs(), openmsx::TclObject::addListElement(), openmsx::XmlOutputArchive::attribute(), openmsx::XmlInputArchive::attribute(), openmsx::ArchiveBase< XmlInputArchive >::attribute(), openmsx::XmlOutputArchive::attributeImpl(), openmsx::XmlInputArchive::attributeImpl(), openmsx::serialize_as_stl_collection< std::vector< T > >::begin(), strCatImpl::calcTotalSize(), strCatImpl::calcTotalSizeHelper(), strCatImpl::ConcatIntegral< T >::ConcatIntegral(), strCatImpl::ConcatUnit< T >::ConcatUnit(), strCatImpl::copyUnits(), strCatImpl::copyUnitsHelper(), cstd::cos_iter(), openmsx::VDPAccessSlots::CycleTable::CycleTable(), openmsx::DivModBySame::div(), openmsx::XMLLoader::XMLElementParser::doctype(), openmsx::DBParser::doctype(), openmsx::InputArchiveBase< XmlInputArchive >::doSerialize(), HexDump::encode(), openmsx::serialize_as_stl_collection< std::vector< T > >::end(), EqualTupleValue(), cstd::exp(), openmsx::DMKDiskImage::getNbSectorsImpl(), openmsx::serialize_as_pointer< std::shared_ptr< T > >::getPointer(), openmsx::serialize_as_pointer< std::unique_ptr< T > >::getPointer(), openmsx::serialize_as_pointer< T * >::getPointer(), openmsx::V9990::getPriorityControlX(), openmsx::V9990::getPriorityControlY(), openmsx::V9990::getRollMask(), openmsx::HD::getTigerTreeHash(), hex_string(), openmsx::PolymorphicInitializer< Archive, T >::init(), openmsx::PolymorphicInitializerRegistry< Archive >::init(), openmsx::SchedulerQueue< openmsx::SynchronizationPoint >::insert(), view::keys(), openmsx::XmlInputArchive::load(), openmsx::MemInputArchive::load(), strCatImpl::makeConcatUnit(), openmsx::MemoryOps::mallocAligned(), openmsx::MB89352::MB89352(), gl::norm2_2(), openmsx::ClassSaver< T >::operator()(), openmsx::PrimitiveSaver< T >::operator()(), openmsx::EnumSaver< T >::operator()(), openmsx::ClassLoader< T >::operator()(), openmsx::PrimitiveLoader< T >::operator()(), openmsx::EnumLoader< T >::operator()(), openmsx::ConditionalNegate< true >::operator()(), openmsx::MapConstrArgsCopy< Base, Derived >::operator()(), openmsx::detail::GetArg< std::optional< T > >::operator()(), SDLDestroyTexture::operator()(), hash_set_impl::Identity::operator()(), Endian::Ident::operator()(), Endian::BSwap::operator()(), strCatImpl::AbsHelper< true >::operator()(), strCatImpl::AbsHelper< false >::operator()(), strCatImpl::PutSignHelper< true >::operator()(), uint128::operator*=(), openmsx::TclObject::operator=(), openmsx::serialize_as_stl_collection< std::vector< T > >::output(), openmsx::Sha1Sum::parse40(), openmsx::Paper::plot(), cb_queue< std::unique_ptr< openmsx::Frame > >::pop_front(), openmsx::serialize_as_stl_collection< std::vector< T > >::prepare(), circular_buffer< std::unique_ptr< openmsx::Frame > >::push_back(), circular_buffer< std::unique_ptr< openmsx::Frame > >::push_front(), openmsx::AY8910::reset(), openmsx::PolymorphicSaverRegistry< Archive >::save(), openmsx::MemOutputArchive::save(), openmsx::XmlOutputArchive::save(), openmsx::XmlOutputArchive::saveImpl(), openmsx::VDP::scheduleCmdSync(), openmsx::serialize(), openmsx::MSXCommandEvent::serialize(), openmsx::YMF278::serialize(), openmsx::MemOutputArchive::serialize(), openmsx::XmlOutputArchive::serialize(), openmsx::InputArchiveBase< XmlInputArchive >::serialize(), openmsx::MemInputArchive::serialize(), openmsx::XmlInputArchive::serialize(), openmsx::ArchiveBase< XmlInputArchive >::serializeBase(), openmsx::ArchiveBase< XmlInputArchive >::serializeInlinedBase(), openmsx::OutputArchiveBase< MemOutputArchive >::serializeInlinedBase(), openmsx::OutputArchiveBase< MemOutputArchive >::serializeOnlyOnce(), openmsx::InputArchiveBase< XmlInputArchive >::serializeOnlyOnce(), openmsx::InputArchiveBase< XmlInputArchive >::serializePointerID(), openmsx::InputArchiveBase< XmlInputArchive >::serializeWithID(), openmsx::DivModBySame::setDivisor(), openmsx::serialize_as_pointer< std::shared_ptr< T > >::setPointer(), openmsx::serialize_as_pointer< std::unique_ptr< T > >::setPointer(), openmsx::serialize_as_pointer< T * >::setPointer(), cstd::sin_iter(), openmsx::DBParser::stop(), strAppend(), strCat(), openmsx::TclObject::TclObject(), TEST_CASE(), openmsx::serialize_as_enum_impl< T >::toString(), view::values(), openmsx::WD33C93::WD33C93(), openmsx::NinjaTap::write(), openmsx::DACSound16S::writeDAC(), and openmsx::AviWriter::~AviWriter().

openmsx::Interpreter
Definition: Interpreter.hh:17