Public Member Functions | |
def | __init__ (self, search_string) |
def | __init__ (self, search_string) |
def | __repr__ (self) |
def | __repr__ (self) |
def | equals (self, rhs) |
def | equals (self, rhs) |
![]() | |
def | __eq__ (self, rhs) |
def | __eq__ (self, rhs) |
def | __ne__ (self, rhs) |
def | __ne__ (self, rhs) |
Private Attributes | |
_search_string | |
Comparison class used to check whether a substring exists in a string parameter. This can be useful in mocking a database with SQL passed in as a string parameter, for example. Example: mock_dao.RunQuery(StrContains('IN (1, 2, 4, 5)')).AndReturn(mock_result)
Definition at line 865 of file bloaty/third_party/protobuf/python/mox.py.
def mox.StrContains.__init__ | ( | self, | |
search_string | |||
) |
Initialize. Args: # search_string: the string you are searching for search_string: str
Definition at line 874 of file bloaty/third_party/protobuf/python/mox.py.
def mox.StrContains.__init__ | ( | self, | |
search_string | |||
) |
Initialize. Args: # search_string: the string you are searching for search_string: str
Definition at line 874 of file protobuf/python/mox.py.
def mox.StrContains.__repr__ | ( | self | ) |
Definition at line 900 of file bloaty/third_party/protobuf/python/mox.py.
def mox.StrContains.__repr__ | ( | self | ) |
Definition at line 900 of file protobuf/python/mox.py.
def mox.StrContains.equals | ( | self, | |
rhs | |||
) |
Check to see if the search_string is contained in the rhs string. Args: # rhs: the right hand side of the test rhs: object Returns: bool
Reimplemented from mox.Comparator.
Definition at line 884 of file protobuf/python/mox.py.
def mox.StrContains.equals | ( | self, | |
rhs | |||
) |
Check to see if the search_string is contained in the rhs string. Args: # rhs: the right hand side of the test rhs: object Returns: bool
Reimplemented from mox.Comparator.
Definition at line 884 of file bloaty/third_party/protobuf/python/mox.py.
|
private |
Definition at line 882 of file bloaty/third_party/protobuf/python/mox.py.