float height = 0.0f;
textEditor.Underline.Find(0, "enable").Get(out enable);
textEditor.Underline.Find(0, "color").Get(color);
- textEditor.Underline.Find(0, "height").Get(out height);\r
-\r
+ textEditor.Underline.Find(0, "height").Get(out height);
+
Assert.AreEqual(true, enable, "enable : should be equals to the set value");
Assert.AreEqual(1.0f, color.R, "color : should be equals to the set value");
Assert.AreEqual(0.1f, height, "height : should be equals to the set value");
[Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
public async Task ScrollStateChanged_CHECK_EVENT()
{
- var textEditor = new TextEditor()\r
- {\r
- Size2D = new Size2D(100, 60),\r
- Text = "Hello Hello World World",\r
- Focusable = true,\r
- };\r
+ var textEditor = new TextEditor()
+ {
+ Size2D = new Size2D(100, 60),
+ Text = "Hello Hello World World",
+ Focusable = true,
+ };
Window.Instance.Add(textEditor);
- try\r
- {\r
- textEditor.ScrollStateChanged += OnScrollStateChanged;\r
- FocusManager.Instance.SetCurrentFocusView(textEditor);\r
- await Task.Delay(500);\r
- Assert.IsTrue(_flagScrollStateChanged, "ScrollStateChanged is not be called");\r
+ try
+ {
+ textEditor.ScrollStateChanged += OnScrollStateChanged;
+ FocusManager.Instance.SetCurrentFocusView(textEditor);
+ await Task.Delay(500);
+ Assert.IsTrue(_flagScrollStateChanged, "ScrollStateChanged is not be called");
}
- catch (Exception e)\r
- {\r
- Tizen.Log.Error(TAG, "Caught Exception" + e.ToString());\r
- LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());\r
- Assert.Fail("Caught Exception" + e.ToString());\r
+ catch (Exception e)
+ {
+ Tizen.Log.Error(TAG, "Caught Exception" + e.ToString());
+ LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());
+ Assert.Fail("Caught Exception" + e.ToString());
}
finally
- {\r
- textEditor.ScrollStateChanged -= OnScrollStateChanged;\r
- Window.Instance.Remove(textEditor);\r
+ {
+ textEditor.ScrollStateChanged -= OnScrollStateChanged;
+ Window.Instance.Remove(textEditor);
}
}
[Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
public void MatchSystemLanguageDirectionProperty_CHECK_VALUE()
{
- var textEditor = new TextEditor();\r
- Assert.IsNotNull(textEditor, "Can't create success object TextEditor");\r
- Assert.IsInstanceOf<TextEditor>(textEditor, "Should be an instance of TextEditor type.");\r
-\r
- textEditor.SetValue(TextEditor.MatchSystemLanguageDirectionProperty, false);\r
- bool ret = (bool)textEditor.GetValue(TextEditor.MatchSystemLanguageDirectionProperty);\r
- Assert.AreEqual(false, ret, "should be same");\r
-\r
- textEditor.SetValue(TextEditor.MatchSystemLanguageDirectionProperty, true);\r
- ret = (bool)textEditor.GetValue(TextEditor.MatchSystemLanguageDirectionProperty);\r
+ var textEditor = new TextEditor();
+ Assert.IsNotNull(textEditor, "Can't create success object TextEditor");
+ Assert.IsInstanceOf<TextEditor>(textEditor, "Should be an instance of TextEditor type.");
+
+ textEditor.SetValue(TextEditor.MatchSystemLanguageDirectionProperty, false);
+ bool ret = (bool)textEditor.GetValue(TextEditor.MatchSystemLanguageDirectionProperty);
+ Assert.AreEqual(false, ret, "should be same");
+
+ textEditor.SetValue(TextEditor.MatchSystemLanguageDirectionProperty, true);
+ ret = (bool)textEditor.GetValue(TextEditor.MatchSystemLanguageDirectionProperty);
Assert.AreEqual(true, ret, "should be same");
}
+
+ [Test]
+ [Category("P1")]
+ [Description("Test MatchSystemLanguageDirection. Check whether MatchSystemLanguageDirection is working correctly or not.")]
+ [Property("SPEC", "Tizen.NUI.BaseComponents.TextEditor.MatchSystemLanguageDirection A")]
+ [Property("SPEC_URL", "-")]
+ [Property("CRITERIA", "PRW")]
+ [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+ public void MatchSystemLanguageDirection_CHECK_VALUE()
+ {
+ var textEditor = new TextEditor();
+ Assert.IsNotNull(textEditor, "Can't create success object TextEditor");
+ Assert.IsInstanceOf<TextEditor>(textEditor, "Should be an instance of TextEditor type.");
+
+ textEditor.MatchSystemLanguageDirection = false;
+ bool ret = textEditor.MatchSystemLanguageDirection;
+ Assert.AreEqual(false, ret, "should be same");
+
+ textEditor.MatchSystemLanguageDirection = true;
+ ret = textEditor.MatchSystemLanguageDirection;
+ Assert.AreEqual(true, ret, "should be same");
+ }
+
}
}
value = new PropertyValue(0.1f);
map.Insert("height", value);
textField.Underline = map;
- Assert.AreEqual(map.Count(), textField.Underline.Count(), "Retrieved Underline' count should be equal to set value");\r
-\r
+ Assert.AreEqual(map.Count(), textField.Underline.Count(), "Retrieved Underline' count should be equal to set value");
+
bool enable = false;
Vector4 color = new Vector4();
float height = 0.0f;
textField.Underline.Find(0, "enable").Get(out enable);
textField.Underline.Find(0, "color").Get(color);
- textField.Underline.Find(0, "height").Get(out height);\r
-\r
+ textField.Underline.Find(0, "height").Get(out height);
+
Assert.AreEqual(true, enable, "enable : should be equals to the set value");
Assert.AreEqual(1.0f, color.R, "color : should be equals to the set value");
Assert.AreEqual(0.1f, height, "height : should be equals to the set value");
[Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
public void MatchSystemLanguageDirectionProperty_CHECK_VALUE()
{
- var textField = new TextField();\r
- Assert.IsNotNull(textField, "Can't create success object TextField");\r
- Assert.IsInstanceOf<TextField>(textField, "Should be an instance of TextField type.");\r
-\r
- textField.SetValue(TextField.MatchSystemLanguageDirectionProperty, false);\r
- bool ret = (bool)textField.GetValue(TextField.MatchSystemLanguageDirectionProperty);\r
+ var textField = new TextField();
+ Assert.IsNotNull(textField, "Can't create success object TextField");
+ Assert.IsInstanceOf<TextField>(textField, "Should be an instance of TextField type.");
+
+ textField.SetValue(TextField.MatchSystemLanguageDirectionProperty, false);
+ bool ret = (bool)textField.GetValue(TextField.MatchSystemLanguageDirectionProperty);
+ Assert.AreEqual(false, ret, "should be same");
+
+ textField.SetValue(TextField.MatchSystemLanguageDirectionProperty, true);
+ ret = (bool)textField.GetValue(TextField.MatchSystemLanguageDirectionProperty);
+ Assert.AreEqual(true, ret, "should be same");
+ }
+
+ [Test]
+ [Category("P1")]
+ [Description("Test MatchSystemLanguageDirection. Check whether MatchSystemLanguageDirection is working correctly or not.")]
+ [Property("SPEC", "Tizen.NUI.BaseComponents.TextField.MatchSystemLanguageDirection A")]
+ [Property("SPEC_URL", "-")]
+ [Property("CRITERIA", "PRW")]
+ [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+ public void MatchSystemLanguageDirection_CHECK_VALUE()
+ {
+ var textField = new TextField();
+ Assert.IsNotNull(textField, "Can't create success object TextField");
+ Assert.IsInstanceOf<TextField>(textField, "Should be an instance of TextField type.");
+
+ textField.MatchSystemLanguageDirection = false;
+ bool ret = textField.MatchSystemLanguageDirection;
Assert.AreEqual(false, ret, "should be same");
- textField.SetValue(TextField.MatchSystemLanguageDirectionProperty, true);\r
- ret = (bool)textField.GetValue(TextField.MatchSystemLanguageDirectionProperty);\r
+ textField.MatchSystemLanguageDirection = true;
+ ret = textField.MatchSystemLanguageDirection;
Assert.AreEqual(true, ret, "should be same");
}
}
map.Insert("height", value);
textLabel.Underline = map;
Assert.AreEqual(map.Count(), textLabel.Underline.Count(), "Retrieved Underline should be equal to set value");
-\r
+
bool enable = false;
Vector4 color = new Vector4();
float height = 0.0f;
textLabel.Underline.Find(0, "enable").Get(out enable);
textLabel.Underline.Find(0, "color").Get(color);
- textLabel.Underline.Find(0, "height").Get(out height);\r
-\r
+ textLabel.Underline.Find(0, "height").Get(out height);
+
Assert.AreEqual(true, enable, "enable : should be equals to the set value");
Assert.AreEqual(1.0f, color.R, "color : should be equals to the set value");
Assert.AreEqual(0.1f, height, "height : should be equals to the set value");
[Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
public void MatchSystemLanguageDirectionProperty_CHECK_VALUE()
{
- var textLabel = new TextLabel();\r
- Assert.IsNotNull(textLabel, "Can't create success object textLabel");\r
- Assert.IsInstanceOf<TextLabel>(textLabel, "Should be an instance of textLabel type.");\r
-\r
- textLabel.SetValue(TextLabel.MatchSystemLanguageDirectionProperty, false);\r
- bool ret = (bool)textLabel.GetValue(TextLabel.MatchSystemLanguageDirectionProperty);\r
+ var textLabel = new TextLabel();
+ Assert.IsNotNull(textLabel, "Can't create success object textLabel");
+ Assert.IsInstanceOf<TextLabel>(textLabel, "Should be an instance of textLabel type.");
+
+ textLabel.SetValue(TextLabel.MatchSystemLanguageDirectionProperty, false);
+ bool ret = (bool)textLabel.GetValue(TextLabel.MatchSystemLanguageDirectionProperty);
+ Assert.AreEqual(false, ret, "should be same");
+
+ textLabel.SetValue(TextLabel.MatchSystemLanguageDirectionProperty, true);
+ ret = (bool)textLabel.GetValue(TextLabel.MatchSystemLanguageDirectionProperty);
+ Assert.AreEqual(true, ret, "should be same");
+ }
+
+ [Test]
+ [Category("P1")]
+ [Description("Test MatchSystemLanguageDirection. Check whether MatchSystemLanguageDirection is working correctly or not.")]
+ [Property("SPEC", "Tizen.NUI.BaseComponents.TextLabel.MatchSystemLanguageDirection A")]
+ [Property("SPEC_URL", "-")]
+ [Property("CRITERIA", "PRW")]
+ [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+ public void MatchSystemLanguageDirection_CHECK_VALUE()
+ {
+ var textLabel = new TextLabel();
+ Assert.IsNotNull(textLabel, "Can't create success object textLabel");
+ Assert.IsInstanceOf<TextLabel>(textLabel, "Should be an instance of textLabel type.");
+
+ textLabel.MatchSystemLanguageDirection = false;
+ bool ret = textLabel.MatchSystemLanguageDirection;
Assert.AreEqual(false, ret, "should be same");
- textLabel.SetValue(TextLabel.MatchSystemLanguageDirectionProperty, true);\r
- ret = (bool)textLabel.GetValue(TextLabel.MatchSystemLanguageDirectionProperty);\r
+ textLabel.MatchSystemLanguageDirection = true;
+ ret = textLabel.MatchSystemLanguageDirection;
Assert.AreEqual(true, ret, "should be same");
}
+
}
public class MyTexLabel : TextLabel