You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
67 lines
2.3 KiB
67 lines
2.3 KiB
# Copyright 2018, The Android Open Source Project
|
|
#
|
|
# Licensed 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.
|
|
|
|
"""
|
|
atest exceptions.
|
|
"""
|
|
|
|
|
|
class UnsupportedModuleTestError(Exception):
|
|
"""Error raised when we find a module that we don't support."""
|
|
|
|
class TestDiscoveryException(Exception):
|
|
"""Base Exception for issues with test discovery."""
|
|
|
|
class NoTestFoundError(TestDiscoveryException):
|
|
"""Raised when no tests are found."""
|
|
|
|
class TestWithNoModuleError(TestDiscoveryException):
|
|
"""Raised when test files have no parent module directory."""
|
|
|
|
class MissingPackageNameError(TestDiscoveryException):
|
|
"""Raised when the test class java file does not contain a package name."""
|
|
|
|
class TooManyMethodsError(TestDiscoveryException):
|
|
"""Raised when input string contains more than one # character."""
|
|
|
|
class MethodWithoutClassError(TestDiscoveryException):
|
|
"""Raised when method is appended via # but no class file specified."""
|
|
|
|
class UnknownTestRunnerError(Exception):
|
|
"""Raised when an unknown test runner is specified."""
|
|
|
|
class NoTestRunnerName(Exception):
|
|
"""Raised when Test Runner class var NAME isn't defined."""
|
|
|
|
class NoTestRunnerExecutable(Exception):
|
|
"""Raised when Test Runner class var EXECUTABLE isn't defined."""
|
|
|
|
class HostEnvCheckFailed(Exception):
|
|
"""Raised when Test Runner's host env check fails."""
|
|
|
|
class ShouldNeverBeCalledError(Exception):
|
|
"""Raised when something is called when it shouldn't, used for testing."""
|
|
|
|
class FatalIncludeError(TestDiscoveryException):
|
|
"""Raised if expanding include tag fails."""
|
|
|
|
class MissingCCTestCaseError(TestDiscoveryException):
|
|
"""Raised when the cc file does not contain a test case class."""
|
|
|
|
class XmlNotExistError(TestDiscoveryException):
|
|
"""Raised when the xml file does not exist."""
|
|
|
|
class DryRunVerificationError(Exception):
|
|
"""Base Exception if verification fail."""
|