Add test case for test font supported by FullType.

This commit is contained in:
WenhaiLin 2015-07-21 17:09:27 +08:00
parent d0d481fd67
commit 979a9be1f5
3 changed files with 26 additions and 1 deletions

View File

@ -83,6 +83,7 @@ NewLabelTests::NewLabelTests()
ADD_TEST_CASE(LabelAddChildTest);
ADD_TEST_CASE(LabelIssue12775Test);
ADD_TEST_CASE(LabelIssue11585Test);
ADD_TEST_CASE(LabelFullTypeFontTest);
};
LabelTTFAlignmentNew::LabelTTFAlignmentNew()
@ -2070,3 +2071,17 @@ std::string LabelIssue11585Test::subtitle() const
{
return "The color of letter should not be overridden by fade action.";
}
LabelFullTypeFontTest::LabelFullTypeFontTest()
{
auto center = VisibleRect::center();
auto label = Label::createWithTTF("Hello 中国", "XueJ2312F.ttf", 30);
label->setPosition(center.x, center.y);
addChild(label);
}
std::string LabelFullTypeFontTest::title() const
{
return "Test font supported by FullType";
}

View File

@ -641,4 +641,14 @@ public:
virtual std::string subtitle() const override;
};
class LabelFullTypeFontTest : public AtlasDemoNew
{
public:
CREATE_FUNC(LabelFullTypeFontTest);
LabelFullTypeFontTest();
virtual std::string title() const override;
};
#endif

@ -1 +1 @@
Subproject commit 37b53805dedbfb1df8549a3e2417df5c47c134ff
Subproject commit a9a4475cbbcc613c3c964a09495a25d652f062f8