X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=automated-tests%2Fsrc%2Fdali-toolkit%2Futc-Dali-TextLabel.cpp;h=621c634dcef0b4856695160d992fec13f1a41230;hp=ecefef74d42a89c39211085a7f40629c046e3461;hb=9c26b8bf8e9f8bc74f809a6ffd2ac2208125bc03;hpb=64b92adb4035ab57f5ad265e0676a8ca8a23c64b diff --git a/automated-tests/src/dali-toolkit/utc-Dali-TextLabel.cpp b/automated-tests/src/dali-toolkit/utc-Dali-TextLabel.cpp index ecefef7..621c634 100644 --- a/automated-tests/src/dali-toolkit/utc-Dali-TextLabel.cpp +++ b/automated-tests/src/dali-toolkit/utc-Dali-TextLabel.cpp @@ -30,6 +30,7 @@ #include #include #include +#include "test-text-geometry-utils.h" using namespace Dali; using namespace Toolkit; @@ -73,6 +74,9 @@ const char* const PROPERTY_NAME_PIXEL_SIZE = "pixelSize"; const char* const PROPERTY_NAME_ELLIPSIS = "ellipsis"; const char* const PROPERTY_NAME_AUTO_SCROLL_LOOP_DELAY = "autoScrollLoopDelay"; const char* const PROPERTY_NAME_FONT_SIZE_SCALE = "fontSizeScale"; +const char* const PROPERTY_NAME_ENABLE_FONT_SIZE_SCALE = "enableFontSizeScale"; + +const char* const PROPERTY_NAME_ELLIPSIS_POSITION = "ellipsisPosition"; const std::string DEFAULT_FONT_DIR( "/resources/fonts" ); const unsigned int EMOJI_FONT_SIZE = 3840u; // 60 * 64 @@ -80,6 +84,8 @@ const unsigned int EMOJI_FONT_SIZE = 3840u; // 60 * 64 static bool gAnchorClickedCallBackCalled; static bool gAnchorClickedCallBackNotCalled; +static bool gTextFitChangedCallBackCalled; + struct CallbackFunctor { CallbackFunctor(bool* callbackFlag) @@ -106,6 +112,12 @@ static void TestAnchorClickedCallback(TextLabel control, const char* href, unsig } } +static void TestTextFitChangedCallback(TextLabel control) +{ + tet_infoline(" TestTextFitChangedCallback"); + gTextFitChangedCallBackCalled = true; +} + bool DaliTestCheckMaps( const Property::Map& mapGet, const Property::Map& mapSet, const std::vector& indexConversionTable = std::vector() ) { const Property::Map::SizeType size = mapGet.Count(); @@ -341,6 +353,8 @@ int UtcDaliToolkitTextLabelGetPropertyP(void) DALI_TEST_CHECK( label.GetPropertyIndex( PROPERTY_NAME_ELLIPSIS ) == TextLabel::Property::ELLIPSIS ); DALI_TEST_CHECK( label.GetPropertyIndex( PROPERTY_NAME_AUTO_SCROLL_LOOP_DELAY ) == TextLabel::Property::AUTO_SCROLL_LOOP_DELAY ); DALI_TEST_CHECK( label.GetPropertyIndex( PROPERTY_NAME_FONT_SIZE_SCALE ) == DevelTextLabel::Property::FONT_SIZE_SCALE ); + DALI_TEST_CHECK( label.GetPropertyIndex( PROPERTY_NAME_ENABLE_FONT_SIZE_SCALE ) == DevelTextLabel::Property::ENABLE_FONT_SIZE_SCALE ); + DALI_TEST_CHECK( label.GetPropertyIndex( PROPERTY_NAME_ELLIPSIS_POSITION ) == DevelTextLabel::Property::ELLIPSIS_POSITION ); END_TEST; } @@ -396,6 +410,10 @@ int UtcDaliToolkitTextLabelSetPropertyP(void) DALI_TEST_EQUALS( label.GetProperty( DevelTextLabel::Property::FONT_SIZE_SCALE ), 2.5f, Math::MACHINE_EPSILON_1000, TEST_LOCATION ); label.SetProperty( DevelTextLabel::Property::FONT_SIZE_SCALE, 1.0f ); + label.SetProperty( DevelTextLabel::Property::ENABLE_FONT_SIZE_SCALE, false ); + DALI_TEST_EQUALS( label.GetProperty( DevelTextLabel::Property::ENABLE_FONT_SIZE_SCALE ), false, TEST_LOCATION ); + label.SetProperty( DevelTextLabel::Property::ENABLE_FONT_SIZE_SCALE, true ); + // Reset font style. fontStyleMapSet.Clear(); fontStyleMapSet.Insert( "weight", "normal" ); @@ -833,6 +851,44 @@ int UtcDaliToolkitTextLabelEmojisP(void) application.SendNotification(); application.Render(); + // EMOJI + ZWJ + EMOJI case for coverage. + const std::string emojiWithZWJ = "👩‍🔬"; + label.SetProperty( TextLabel::Property::TEXT, emojiWithZWJ ); + + application.SendNotification(); + application.Render(); + + // EMOJI Sequences case for coverage. + std::string emojiSequences = + "Text VS15 ☪︎\n" //text presentation sequence and selector + "Color VS16 ☪️\n" //emoji presentation sequence and selector + "Default ☪ \n" //default presentation + "FamilyManWomanGirlBoy 👨‍👩‍👧‍👦\n" // emoji multi zwj sequence + "WomanScientist 👩‍🔬\n" // emoji zwj sequence + "WomanScientistLightSkinTone👩🏻‍🔬 \n" //emoji modifier sequence: skin tone & JWZ + "LeftRightArrowText↔︎\n" //text presentation sequence and selector + "LeftRightArrowEmoji↔️\n" //emoji presentation sequence and selector + "SouthKoreaFlag🇰🇷\n" //emoji flag sequence + "JordanFlag🇯🇴\n" // emoji flag sequence + "EnglandFlag🏴󠁧󠁢󠁥󠁮󠁧󠁿\n" //emoji tag sequence like England flag + "Runner 🏃‍➡️ \n" + "VictoryHandMediumLightSkinTone:✌️🏼\n" //emoji modifier sequence: skin tone + "RainbowFlag:🏳️‍🌈 \n" //emoji zwj sequence: Rainbow Flag + "keycap# #️⃣ \n" // fully-qualified emoji keycap sequence + "keycap#_text #⃣ \n" // unqualified emoji keycap sequence + "keycap3 3️⃣ \n" // fully-qualified emoji keycap sequence + "keycap3_text 3⃣ \n" // unqualified emoji keycap sequence + "two adjacent glyphs ☪️️️☪️\n" //This line should be rendered as two adjacent glyphs + "Digit 8️ 8︎ 8\n" // should be rendered according to selector + "Surfing Medium Skin Female: 🏄🏼‍♀️"; // Person Surfing + Medium Skin Tone +? Zero Width Joiner + Female Sign + + label.SetProperty( TextLabel::Property::TEXT, emojiSequences ); + label.SetProperty( TextLabel::Property::ENABLE_MARKUP, true ); + label.SetProperty( TextLabel::Property::MULTI_LINE, true); + label.SetProperty( TextLabel::Property::ELLIPSIS, false); + + application.SendNotification(); + application.Render(); END_TEST; } @@ -1512,6 +1568,7 @@ int UtcDaliToolkitTextlabelTextDirection(void) label.SetProperty( TextLabel::Property::TEXT, "Hello world" ); label.SetProperty( TextLabel::Property::POINT_SIZE, 20 ); + label.SetProperty( DevelTextLabel::Property::MATCH_SYSTEM_LANGUAGE_DIRECTION, false ); application.GetScene().Add( label ); // Test LTR text @@ -1621,6 +1678,13 @@ int UtcDaliToolkitTextlabelTextFit(void) label.SetProperty( Actor::Property::SIZE, size ); label.SetProperty( TextLabel::Property::TEXT, "Hello world" ); + // connect to the text git changed signal. + ConnectionTracker* testTracker = new ConnectionTracker(); + DevelTextLabel::TextFitChangedSignal(label).Connect(&TestTextFitChangedCallback); + bool textFitChangedSignal = false; + label.ConnectSignal(testTracker, "textFitChanged", CallbackFunctor(&textFitChangedSignal)); + gTextFitChangedCallBackCalled = false; + // check point size Property::Map textFitMapSet; textFitMapSet["enable"] = true; @@ -1637,9 +1701,12 @@ int UtcDaliToolkitTextlabelTextFit(void) application.SendNotification(); application.Render(); - const Vector3 EXPECTED_NATURAL_SIZE( 452.0f, 94.0f, 0.0f ); + const Vector3 EXPECTED_NATURAL_SIZE( 450.0f, 96.0f, 0.0f ); DALI_TEST_EQUALS( EXPECTED_NATURAL_SIZE, label.GetNaturalSize(), TEST_LOCATION ); + DALI_TEST_CHECK(gTextFitChangedCallBackCalled); + DALI_TEST_CHECK(textFitChangedSignal); + // check pixel size textFitMapSet.Clear(); textFitMapSet["enable"] = true; @@ -1784,7 +1851,34 @@ int UtcDaliToolkitTextlabelAnchorClicked(void) application.Render(); // Create a tap event to touch the text label. - TestGenerateTap(application, 5.0f, 25.0f); + TestGenerateTap(application, 5.0f, 25.0f, 100); + application.SendNotification(); + application.Render(); + + DALI_TEST_CHECK(gAnchorClickedCallBackCalled); + DALI_TEST_CHECK(anchorClickedSignal); + + // reset + gAnchorClickedCallBackCalled = false; + anchorClickedSignal = false; + label.SetProperty(TextLabel::Property::TEXT, ""); + label.SetProperty(TextLabel::Property::ENABLE_MARKUP, false); + + application.SendNotification(); + application.Render(); + + // sets anchor text + label.SetProperty(TextLabel::Property::ENABLE_MARKUP, true); + label.SetProperty(TextLabel::Property::TEXT, "TIZEN"); + label.SetProperty(Actor::Property::SIZE, Vector2(100.f, 50.f)); + label.SetProperty(Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT); + label.SetProperty(Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT); + + application.SendNotification(); + application.Render(); + + // Create a tap event to touch the text label. + TestGenerateTap(application, 5.0f, 25.0f, 200); application.SendNotification(); application.Render(); @@ -1794,7 +1888,7 @@ int UtcDaliToolkitTextlabelAnchorClicked(void) gAnchorClickedCallBackNotCalled = true; // Tap the outside of anchor, callback should not be called. - TestGenerateTap(application, 150.f, 100.f); + TestGenerateTap(application, 150.f, 100.f, 300); application.SendNotification(); application.Render(); @@ -1802,3 +1896,291 @@ int UtcDaliToolkitTextlabelAnchorClicked(void) END_TEST; } + +int UtcDaliTextLabelAtlasLimitationIsEnabledForLargeFontPointSize(void) +{ + ToolkitTestApplication application; + tet_infoline(" UtcDaliTextLabelAtlasLimitationIsEnabledForLargeFontPointSize "); + + //TextLabel is not using Atlas but this is to unify font-size on text-controllers + + // +2: First one to handle the equal case. Second one to handle odd to even case of GetNaturalSize + const uint32_t lessThanWidth = TextAbstraction::FontClient::MAX_TEXT_ATLAS_WIDTH - TextAbstraction::FontClient::PADDING_TEXT_ATLAS_BLOCK + 2; + const uint32_t lessThanHeight = TextAbstraction::FontClient::MAX_TEXT_ATLAS_HEIGHT - TextAbstraction::FontClient::PADDING_TEXT_ATLAS_BLOCK + 2; + + // Create a text editor + TextLabel textLabel = TextLabel::New(); + //Set size to avoid automatic eliding + textLabel.SetProperty( Actor::Property::SIZE, Vector2(1025, 1025)); + //Set very large font-size using point-size + textLabel.SetProperty( TextLabel::Property::POINT_SIZE, 1000); + //Specify font-family + textLabel.SetProperty( TextLabel::Property::FONT_FAMILY, "DejaVu Sans"); + //Set text to check if appear or not + textLabel.SetProperty( TextLabel::Property::TEXT, "A"); + + application.GetScene().Add( textLabel ); + + application.SendNotification(); + application.Render(); + //Use GetNaturalSize to verify that size of block does not exceed Atlas size + Vector3 naturalSize = textLabel.GetNaturalSize(); + + DALI_TEST_GREATER( lessThanWidth, static_cast(naturalSize.width), TEST_LOCATION ); + DALI_TEST_GREATER( lessThanHeight, static_cast(naturalSize.height), TEST_LOCATION ); + + END_TEST; +} + +int UtcDaliTextLabelHyphenWrapMode(void) +{ + ToolkitTestApplication application; + tet_infoline(" UtcDaliTextLabelHyphenWrapMode "); + + int lineCount =0; + TextLabel label = TextLabel::New(); + label.SetProperty( Actor::Property::SIZE, Vector2( 150.0f, 300.f )); + label.SetProperty( TextLabel::Property::POINT_SIZE, 12.f ); + label.SetProperty( TextLabel::Property::MULTI_LINE, true); + application.GetScene().Add( label ); + application.SendNotification(); + application.Render(); + + label.SetProperty( TextLabel::Property::TEXT, "Hi Experimen" ); + label.SetProperty(TextLabel::Property::LINE_WRAP_MODE,DevelText::LineWrap::HYPHENATION); + DALI_TEST_EQUALS( label.GetProperty< int >( TextLabel::Property::LINE_WRAP_MODE ), static_cast< int >( DevelText::LineWrap::HYPHENATION ), TEST_LOCATION ); + + application.SendNotification(); + application.Render(); + + lineCount = label.GetProperty( TextLabel::Property::LINE_COUNT ); + /* + text will be : + Hi Exp- + erimen + */ + DALI_TEST_EQUALS( lineCount, 2, TEST_LOCATION ); + + label.SetProperty( TextLabel::Property::TEXT, "Hi Experimen" ); + label.SetProperty(TextLabel::Property::LINE_WRAP_MODE,DevelText::LineWrap::MIXED); + DALI_TEST_EQUALS( label.GetProperty< int >( TextLabel::Property::LINE_WRAP_MODE ), static_cast< int >( DevelText::LineWrap::MIXED ), TEST_LOCATION ); + + application.SendNotification(); + application.Render(); + + lineCount = label.GetProperty( TextLabel::Property::LINE_COUNT ); + /* + text will be : + Hi + Experi- + men + */ + DALI_TEST_EQUALS( lineCount, 3, TEST_LOCATION ); + + END_TEST; +} + + +int utcDaliTextLabelGetHeightForWidthChangeLineCountWhenTextChanged(void) +{ + ToolkitTestApplication application; + + tet_infoline(" utcDaliTextLabelGetHeightForWidthChangeLineCountWhenTextChanged "); + + int lineCountBefore =0 ; + int lineCountAfter =0 ; + + // Create a text editor + TextLabel textLabel = TextLabel::New(); + //Set very large font-size using point-size + textLabel.SetProperty( TextLabel::Property::POINT_SIZE, 10) ; + //Specify font-family + textLabel.SetProperty( TextLabel::Property::FONT_FAMILY, "DejaVu Sans"); + //Specify size + textLabel.SetProperty( Actor::Property::SIZE, Vector2( 200.f, 100.f ) ); + //Set text longer than width of textLabel + textLabel.SetProperty( TextLabel::Property::TEXT, "Short text"); + //Set line wrap mode Character + textLabel.SetProperty(TextLabel::Property::LINE_WRAP_MODE, "CHARACTER"); + textLabel.SetProperty(TextLabel::Property::MULTI_LINE, true); + + application.GetScene().Add( textLabel ); + + application.SendNotification(); + application.Render(); + + + lineCountBefore = textLabel.GetProperty( TextLabel::Property::LINE_COUNT ); + + textLabel.SetProperty( TextLabel::Property::TEXT, "This is very loooooooooooooooooooooooooooooooooooong text for test"); + lineCountAfter = textLabel.GetProperty( TextLabel::Property::LINE_COUNT ); + + // When the text changed, the Line-count should be updated according to new text. + // Because the GetHeightForWidth is called in Controller::GetLineCount(float width) + DALI_TEST_EQUALS( lineCountBefore ,1, TEST_LOCATION ); + DALI_TEST_GREATER( lineCountAfter,1, TEST_LOCATION ); + + + END_TEST; +} + +int utcDaliTextLabelGeometryRTL(void) +{ + ToolkitTestApplication application; + tet_infoline(" utcDaliTextLabelGeometryRTL"); + + TextLabel label = TextLabel::New(); + DALI_TEST_CHECK( label ); + + application.GetScene().Add( label ); + + label.SetProperty( TextLabel::Property::POINT_SIZE, 7.f ); + label.SetProperty( Actor::Property::SIZE, Vector2( 150.f, 100.f ) ); + label.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT ); + label.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT ); + label.SetProperty( TextLabel::Property::ENABLE_MARKUP, true ); + label.SetProperty( TextLabel::Property::MULTI_LINE, true); + label.SetProperty( TextLabel::Property::TEXT, "line1 \nline2\nline 3\nالاخيرالسطر" ); + + // Avoid a crash when core load gl resources. + application.GetGlAbstraction().SetCheckFramebufferStatusResult( GL_FRAMEBUFFER_COMPLETE ); + + // Render and notify + application.SendNotification(); + application.Render(); + + unsigned int expectedCount = 4; + unsigned int startIndex = 3; + unsigned int endIndex = 24; + + Vector positionsList = DevelTextLabel::GetTextPosition(label, startIndex, endIndex); + Vector sizeList = DevelTextLabel::GetTextSize(label, startIndex, endIndex); + + DALI_TEST_EQUALS(positionsList.Size(), expectedCount, TEST_LOCATION); + DALI_TEST_EQUALS(sizeList.Size(), expectedCount, TEST_LOCATION); + + Vector expectedSizes; + Vector expectedPositions; + + expectedPositions.PushBack(Vector2(24, 0)); + expectedSizes.PushBack(Vector2(33, 25)); + + expectedPositions.PushBack(Vector2(-1, 25)); + expectedSizes.PushBack(Vector2(52, 25)); + + expectedPositions.PushBack(Vector2(-1, 50)); + expectedSizes.PushBack(Vector2(59, 25)); + + expectedPositions.PushBack(Vector2(73, 75)); + expectedSizes.PushBack(Vector2(37, 25)); + + TestTextGeometryUtils::CheckGeometryResult(positionsList, sizeList, expectedPositions, expectedSizes); + + END_TEST; +} + +int utcDaliTextLabelGeometryGlyphMiddle(void) +{ + ToolkitTestApplication application; + tet_infoline(" utcDaliTextLabelGeometryGlyphMiddle"); + + TextLabel label = TextLabel::New(); + DALI_TEST_CHECK( label ); + + application.GetScene().Add( label ); + + label.SetProperty( TextLabel::Property::POINT_SIZE, 7.f ); + label.SetProperty( Actor::Property::SIZE, Vector2( 200.f, 200.f ) ); + label.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT ); + label.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT ); + label.SetProperty( TextLabel::Property::ENABLE_MARKUP, true ); + label.SetProperty( TextLabel::Property::TEXT, "لا تحتوي على لا" ); + + // Avoid a crash when core load gl resources. + application.GetGlAbstraction().SetCheckFramebufferStatusResult( GL_FRAMEBUFFER_COMPLETE ); + + // Render and notify + application.SendNotification(); + application.Render(); + + unsigned int expectedCount = 1; + unsigned int startIndex = 1; + unsigned int endIndex = 13; + + Vector positionsList = DevelTextLabel::GetTextPosition(label, startIndex, endIndex); + Vector sizeList = DevelTextLabel::GetTextSize(label, startIndex, endIndex); + + DALI_TEST_EQUALS(positionsList.Size(), expectedCount, TEST_LOCATION); + DALI_TEST_EQUALS(sizeList.Size(), expectedCount, TEST_LOCATION); + + Vector expectedSizes; + Vector expectedPositions; + + expectedPositions.PushBack(Vector2(12, 0)); + expectedSizes.PushBack(Vector2(118, 25)); + + TestTextGeometryUtils::CheckGeometryResult(positionsList, sizeList, expectedPositions, expectedSizes); + + END_TEST; +} + +int UtcDaliToolkitTextlabelEllipsisPositionProperty(void) +{ + ToolkitTestApplication application; + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty "); + TextLabel textLabel = TextLabel::New(); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Default is END"); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::END ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to START"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, DevelText::EllipsisPosition::START); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::START ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to MIDDLE"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, DevelText::EllipsisPosition::MIDDLE); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::MIDDLE ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to END"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, DevelText::EllipsisPosition::END); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::END ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to START using integer"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, 1); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::START ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to MIDDLE using integer"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, 2); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::MIDDLE ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to END using integer"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, 0); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::END ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to START using string - uppercase"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, "START"); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::START ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to MIDDLE using string - uppercase"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, "MIDDLE"); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::MIDDLE ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to END using string - uppercase"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, "END"); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::END ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to START using string - lowercase"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, "start"); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::START ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to MIDDLE using string - lowercase"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, "middle"); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::MIDDLE ), TEST_LOCATION ); + + tet_infoline(" UtcDaliToolkitTextlabelEllipsisPositionProperty - Change to END using string - lowercase"); + textLabel.SetProperty(DevelTextLabel::Property::ELLIPSIS_POSITION, "end"); + DALI_TEST_EQUALS( textLabel.GetProperty< int >( DevelTextLabel::Property::ELLIPSIS_POSITION ), static_cast< int >( Toolkit::DevelText::EllipsisPosition::END ), TEST_LOCATION ); + + + END_TEST; +}