String stream test << operator in etl namespace

This commit is contained in:
John Wellbelove 2020-08-07 09:57:34 +01:00
parent cb7e224f93
commit b5bdb4f566
3 changed files with 25 additions and 6 deletions

View File

@ -41,10 +41,10 @@ SOFTWARE.
namespace
{
using String = etl::u16string<50>;
using String = etl::u16string<50>;
using IString = etl::iu16string;
using Stream = etl::u16string_stream;
using Format = etl::u16format_spec;
using Stream = etl::u16string_stream;
using Format = etl::u16format_spec;
//***********************************
struct Custom
@ -59,7 +59,10 @@ namespace
ss << STR("X = ") << value.x << STR(" : Y = ") << value.y;
return ss;
}
}
namespace etl
{
//***********************************
std::ostream& operator << (std::ostream& os, const IString& str)
{
@ -70,7 +73,10 @@ namespace
return os;
}
}
namespace
{
SUITE(test_string_stream)
{
//*************************************************************************

View File

@ -41,10 +41,10 @@ SOFTWARE.
namespace
{
using String = etl::u32string<50>;
using String = etl::u32string<50>;
using IString = etl::iu32string;
using Stream = etl::u32string_stream;
using Format = etl::u32format_spec;
using Stream = etl::u32string_stream;
using Format = etl::u32format_spec;
//***********************************
struct Custom
@ -59,7 +59,10 @@ namespace
ss << STR("X = ") << value.x << STR(" : Y = ") << value.y;
return ss;
}
}
namespace etl
{
//***********************************
std::ostream& operator << (std::ostream& os, const IString& str)
{
@ -70,7 +73,10 @@ namespace
return os;
}
}
namespace
{
SUITE(test_string_stream)
{
//*************************************************************************

View File

@ -59,7 +59,10 @@ namespace
ss << STR("X = ") << value.x << STR(" : Y = ") << value.y;
return ss;
}
}
namespace etl
{
//***********************************
std::ostream& operator << (std::ostream& os, const IString& str)
{
@ -70,6 +73,10 @@ namespace
return os;
}
}
namespace
{
SUITE(test_string_stream)
{