mirror of
https://github.com/httprunner/httprunner.git
synced 2026-07-10 23:12:41 +08:00
change: simplify testcase import
This commit is contained in:
@@ -1,11 +1,8 @@
|
|||||||
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
||||||
import unittest
|
from httprunner import HttpRunner, TConfig, TStep, TestCase
|
||||||
|
|
||||||
from httprunner.runner import HttpRunner
|
|
||||||
from httprunner.schema import TConfig, TStep
|
|
||||||
|
|
||||||
|
|
||||||
class TestCaseHardcode(unittest.TestCase):
|
class TestCaseHardcode(TestCase):
|
||||||
config = TConfig(
|
config = TConfig(
|
||||||
**{
|
**{
|
||||||
"name": "request methods testcase in hardcode",
|
"name": "request methods testcase in hardcode",
|
||||||
|
|||||||
@@ -1,11 +1,8 @@
|
|||||||
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
||||||
import unittest
|
from httprunner import HttpRunner, TConfig, TStep, TestCase
|
||||||
|
|
||||||
from httprunner.runner import HttpRunner
|
|
||||||
from httprunner.schema import TConfig, TStep
|
|
||||||
|
|
||||||
|
|
||||||
class TestCaseRequestWithFunctions(unittest.TestCase):
|
class TestCaseRequestWithFunctions(TestCase):
|
||||||
config = TConfig(
|
config = TConfig(
|
||||||
**{
|
**{
|
||||||
"name": "request methods testcase with functions",
|
"name": "request methods testcase with functions",
|
||||||
|
|||||||
@@ -1,11 +1,8 @@
|
|||||||
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
||||||
import unittest
|
from httprunner import HttpRunner, TConfig, TStep, TestCase
|
||||||
|
|
||||||
from httprunner.runner import HttpRunner
|
|
||||||
from httprunner.schema import TConfig, TStep
|
|
||||||
|
|
||||||
|
|
||||||
class TestCaseRequestWithTestcaseReference(unittest.TestCase):
|
class TestCaseRequestWithTestcaseReference(TestCase):
|
||||||
config = TConfig(
|
config = TConfig(
|
||||||
**{
|
**{
|
||||||
"name": "request methods testcase: reference testcase",
|
"name": "request methods testcase: reference testcase",
|
||||||
|
|||||||
@@ -1,11 +1,8 @@
|
|||||||
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
||||||
import unittest
|
from httprunner import HttpRunner, TConfig, TStep, TestCase
|
||||||
|
|
||||||
from httprunner.runner import HttpRunner
|
|
||||||
from httprunner.schema import TConfig, TStep
|
|
||||||
|
|
||||||
|
|
||||||
class TestCaseRequestWithVariables(unittest.TestCase):
|
class TestCaseRequestWithVariables(TestCase):
|
||||||
config = TConfig(
|
config = TConfig(
|
||||||
**{
|
**{
|
||||||
"name": "request methods testcase with variables",
|
"name": "request methods testcase with variables",
|
||||||
|
|||||||
@@ -1,11 +1,8 @@
|
|||||||
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
||||||
import unittest
|
from httprunner import HttpRunner, TConfig, TStep, TestCase
|
||||||
|
|
||||||
from httprunner.runner import HttpRunner
|
|
||||||
from httprunner.schema import TConfig, TStep
|
|
||||||
|
|
||||||
|
|
||||||
class TestCaseValidateWithFunctions(unittest.TestCase):
|
class TestCaseValidateWithFunctions(TestCase):
|
||||||
config = TConfig(
|
config = TConfig(
|
||||||
**{
|
**{
|
||||||
"name": "request methods testcase: validate with functions",
|
"name": "request methods testcase: validate with functions",
|
||||||
|
|||||||
@@ -1,11 +1,8 @@
|
|||||||
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
||||||
import unittest
|
from httprunner import HttpRunner, TConfig, TStep, TestCase
|
||||||
|
|
||||||
from httprunner.runner import HttpRunner
|
|
||||||
from httprunner.schema import TConfig, TStep
|
|
||||||
|
|
||||||
|
|
||||||
class TestCaseValidateWithVariables(unittest.TestCase):
|
class TestCaseValidateWithVariables(TestCase):
|
||||||
config = TConfig(
|
config = TConfig(
|
||||||
**{
|
**{
|
||||||
"name": "request methods testcase: validate with variables",
|
"name": "request methods testcase: validate with variables",
|
||||||
|
|||||||
@@ -1,4 +1,15 @@
|
|||||||
__version__ = "3.0.2"
|
__version__ = "3.0.2"
|
||||||
__description__ = "One-stop solution for HTTP(S) testing."
|
__description__ = "One-stop solution for HTTP(S) testing."
|
||||||
|
|
||||||
__all__ = ["__version__", "__description__"]
|
from unittest import TestCase
|
||||||
|
from httprunner.runner import HttpRunner
|
||||||
|
from httprunner.schema import TConfig, TStep
|
||||||
|
|
||||||
|
__all__ = [
|
||||||
|
"__version__",
|
||||||
|
"__description__",
|
||||||
|
"HttpRunner",
|
||||||
|
"TConfig",
|
||||||
|
"TStep",
|
||||||
|
"TestCase",
|
||||||
|
]
|
||||||
|
|||||||
@@ -10,13 +10,10 @@ from httprunner.exceptions import TestCaseFormatError
|
|||||||
from httprunner.loader import load_testcase_file, load_folder_files
|
from httprunner.loader import load_testcase_file, load_folder_files
|
||||||
|
|
||||||
__TMPL__ = """# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
__TMPL__ = """# NOTICE: Generated By HttpRunner. DO'NOT EDIT!
|
||||||
import unittest
|
from httprunner import HttpRunner, TConfig, TStep, TestCase
|
||||||
|
|
||||||
from httprunner.runner import HttpRunner
|
|
||||||
from httprunner.schema import TConfig, TStep
|
|
||||||
|
|
||||||
|
|
||||||
class {{ class_name }}(unittest.TestCase):
|
class {{ class_name }}(TestCase):
|
||||||
config = TConfig(**{{ config }})
|
config = TConfig(**{{ config }})
|
||||||
|
|
||||||
teststeps = [
|
teststeps = [
|
||||||
|
|||||||
Reference in New Issue
Block a user