IT. Expert System.

Android Reference

ViewAsserts


android.test

Class ViewAsserts



  • public class ViewAsserts
    extends Object
    Some useful assertions about views.
    • Method Detail

      • assertOnScreen

        public static void assertOnScreen(View origin,
                          View view)
        Assert that view is on the screen.
        Parameters:
        origin - The root view of the screen.
        view - The view.
      • assertOffScreenBelow

        public static void assertOffScreenBelow(View origin,
                                View view)
        Assert that view is below the visible screen.
        Parameters:
        origin - The root view of the screen.
        view - The view
      • assertOffScreenAbove

        public static void assertOffScreenAbove(View origin,
                                View view)
        Assert that view is above the visible screen.
        Parameters:
        origin - Te root view of the screen.
        view - The view
      • assertHasScreenCoordinates

        public static void assertHasScreenCoordinates(View origin,
                                      View view,
                                      int x,
                                      int y)
        Assert that a view has a particular x and y position on the visible screen.
        Parameters:
        origin - The root view of the screen.
        view - The view.
        x - The expected x coordinate.
        y - The expected y coordinate.
      • assertBaselineAligned

        public static void assertBaselineAligned(View first,
                                 View second)
        Assert that two views are aligned on their baseline, that is that their baselines are on the same y location.
        Parameters:
        first - The first view
        second - The second view
      • assertRightAligned

        public static void assertRightAligned(View first,
                              View second)
        Assert that two views are right aligned, that is that their right edges are on the same x location.
        Parameters:
        first - The first view
        second - The second view
      • assertRightAligned

        public static void assertRightAligned(View first,
                              View second,
                              int margin)
        Assert that two views are right aligned, that is that their right edges are on the same x location, with respect to the specified margin.
        Parameters:
        first - The first view
        second - The second view
        margin - The margin between the first view and the second view
      • assertLeftAligned

        public static void assertLeftAligned(View first,
                             View second)
        Assert that two views are left aligned, that is that their left edges are on the same x location.
        Parameters:
        first - The first view
        second - The second view
      • assertLeftAligned

        public static void assertLeftAligned(View first,
                             View second,
                             int margin)
        Assert that two views are left aligned, that is that their left edges are on the same x location, with respect to the specified margin.
        Parameters:
        first - The first view
        second - The second view
        margin - The margin between the first view and the second view
      • assertBottomAligned

        public static void assertBottomAligned(View first,
                               View second)
        Assert that two views are bottom aligned, that is that their bottom edges are on the same y location.
        Parameters:
        first - The first view
        second - The second view
      • assertBottomAligned

        public static void assertBottomAligned(View first,
                               View second,
                               int margin)
        Assert that two views are bottom aligned, that is that their bottom edges are on the same y location, with respect to the specified margin.
        Parameters:
        first - The first view
        second - The second view
        margin - The margin between the first view and the second view
      • assertTopAligned

        public static void assertTopAligned(View first,
                            View second)
        Assert that two views are top aligned, that is that their top edges are on the same y location.
        Parameters:
        first - The first view
        second - The second view
      • assertTopAligned

        public static void assertTopAligned(View first,
                            View second,
                            int margin)
        Assert that two views are top aligned, that is that their top edges are on the same y location, with respect to the specified margin.
        Parameters:
        first - The first view
        second - The second view
        margin - The margin between the first view and the second view
      • assertHorizontalCenterAligned

        public static void assertHorizontalCenterAligned(View reference,
                                         View test)
        Assert that the test view is horizontally center aligned with respect to the reference view.
        Parameters:
        reference - The reference view
        test - The view that should be center aligned with the reference view
      • assertVerticalCenterAligned

        public static void assertVerticalCenterAligned(View reference,
                                       View test)
        Assert that the test view is vertically center aligned with respect to the reference view.
        Parameters:
        reference - The reference view
        test - The view that should be center aligned with the reference view
      • assertGroupIntegrity

        public static void assertGroupIntegrity(ViewGroup parent)
        Assert the specified group's integrity. The children count should be >= 0 and each child should be non-null.
        Parameters:
        parent - The group whose integrity to check
      • assertGroupContains

        public static void assertGroupContains(ViewGroup parent,
                               View child)
        Assert that the specified group contains a specific child once and only once.
        Parameters:
        parent - The group
        child - The child that should belong to group
      • assertGroupNotContains

        public static void assertGroupNotContains(ViewGroup parent,
                                  View child)
        Assert that the specified group does not contain a specific child.
        Parameters:
        parent - The group
        child - The child that should not belong to group


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 11131 / . Delta: 0.04727 с