You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by mi...@apache.org on 2015/01/15 18:13:49 UTC

[2/6] git commit: [flex-utilities] [refs/heads/develop] - FLEX-34717 Added a unit test to reproduce the bug. Currently it fails.

FLEX-34717 Added a unit test to reproduce the bug. Currently it fails.


Project: http://git-wip-us.apache.org/repos/asf/flex-utilities/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-utilities/commit/4ceb81a5
Tree: http://git-wip-us.apache.org/repos/asf/flex-utilities/tree/4ceb81a5
Diff: http://git-wip-us.apache.org/repos/asf/flex-utilities/diff/4ceb81a5

Branch: refs/heads/develop
Commit: 4ceb81a5bcadbe461b4caae95866ee255ad485ef
Parents: fff4c4f
Author: Mihai Chira <mi...@apache.org>
Authored: Thu Jan 15 16:38:17 2015 +0000
Committer: Mihai Chira <mi...@apache.org>
Committed: Thu Jan 15 16:38:17 2015 +0000

----------------------------------------------------------------------
 .../linguistics/spelling/FLEX_34717_Test.as     | 57 ++++++++++++++++++++
 1 file changed, 57 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/4ceb81a5/Squiggly/main/SpellingUIEx/src/tests/com/adobe/linguistics/spelling/FLEX_34717_Test.as
----------------------------------------------------------------------
diff --git a/Squiggly/main/SpellingUIEx/src/tests/com/adobe/linguistics/spelling/FLEX_34717_Test.as b/Squiggly/main/SpellingUIEx/src/tests/com/adobe/linguistics/spelling/FLEX_34717_Test.as
new file mode 100644
index 0000000..4d6a357
--- /dev/null
+++ b/Squiggly/main/SpellingUIEx/src/tests/com/adobe/linguistics/spelling/FLEX_34717_Test.as
@@ -0,0 +1,57 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package com.adobe.linguistics.spelling {
+    import com.adobe.linguistics.spelling.SpellUI;
+
+    import mx.controls.TextArea;
+
+    import org.flexunit.asserts.assertTrue;
+    import org.fluint.uiImpersonation.UIImpersonator;
+
+    public class FLEX_34717_Test {
+        private var _input:TextArea;
+
+        [Before]
+        public function setUp():void
+        {
+            _input = new TextArea();
+        }
+
+        [After]
+        public function tearDown():void
+        {
+            _input = null;
+        }
+
+        [Test]
+        public function test_immediate_disable_after_enable():void
+        {
+            //given
+            UIImpersonator.addChild(_input);
+
+            //when
+            SpellUI.enableSpelling(_input, "en_US");
+            SpellUI.disableSpelling(_input);
+
+            //then
+            assertTrue(true); //no error was thrown
+        }
+    }
+}