Ejemplo n.º 1
0
        public void ByTooltip()
        {
            // Text
            FlutterDriver.Click(FlutterBy.Tooltip("FUT: FlutterBy.Tooltip (Increment 3)"));

            AssertCounterIs("3", because: "we pressed the Add+3 button");
        }
Ejemplo n.º 2
0
        public void GetSemanticsId_ByScript()
        {
            var result = FlutterDriver.ExecuteScript("flutter:getSemanticsId", FlutterBy.Tooltip("FUT: FlutterBy.Tooltip (Increment 3)").ToBase64());

            result.Should().BeOfType(typeof(long));

            ((long)result).Should().NotBe(0);
        }
Ejemplo n.º 3
0
        public void ByTooltip(string inputText, string nodeOutputAsBase64)
        {
            // NodeJs Snippet:
            // console.log(find.byTooltip(null))
            // console.log(find.byTooltip(""))
            // console.log(find.byTooltip(" "))
            // console.log(find.byTooltip("theText"))

            // Output:
            // eyJmaW5kZXJUeXBlIjoiQnlUb29sdGlwTWVzc2FnZSIsInRleHQiOm51bGx9
            // eyJmaW5kZXJUeXBlIjoiQnlUb29sdGlwTWVzc2FnZSIsInRleHQiOiIifQ
            // eyJmaW5kZXJUeXBlIjoiQnlUb29sdGlwTWVzc2FnZSIsInRleHQiOiIgIn0
            // eyJmaW5kZXJUeXBlIjoiQnlUb29sdGlwTWVzc2FnZSIsInRleHQiOiJ0aGVUZXh0In0
            var asPageBackFinder = FlutterBy.Tooltip(inputText);

            var asBase64 = asPageBackFinder.ToBase64();

            asBase64.Should().Be(nodeOutputAsBase64, because: "the Base64 Serialization should match the NodeJs version");
        }