Commit 31d2f8e5 authored by lanjiali's avatar lanjiali

校区费用预警-查询

parent afbc1bd1
...@@ -19,10 +19,10 @@ ...@@ -19,10 +19,10 @@
<select /> <select />
</component> </component>
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="54f4d37d-1724-4813-a1e2-24e200088c5f" name="Default Changelist" comment="学生费用预警查询-分页"> <list default="true" id="54f4d37d-1724-4813-a1e2-24e200088c5f" name="Default Changelist" comment="校区费用预警-查询">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" /> <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/run.py" beforeDir="false" afterPath="$PROJECT_DIR$/run.py" afterDir="false" /> <change beforePath="$PROJECT_DIR$/run.py" beforeDir="false" afterPath="$PROJECT_DIR$/run.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/script/ji_yun_ying_pc/lanjiali_report/data_config/report_config.py" beforeDir="false" afterPath="$PROJECT_DIR$/script/ji_yun_ying_pc/lanjiali_report/data_config/report_config.py" afterDir="false" /> <change beforePath="$PROJECT_DIR$/script/ji_yun_ying_pc/lanjiali_report/test_demo.py" beforeDir="false" afterPath="$PROJECT_DIR$/script/ji_yun_ying_pc/lanjiali_report/test_demo.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/script/ji_yun_ying_pc/lanjiali_report/test_school_expense.py" beforeDir="false" afterPath="$PROJECT_DIR$/script/ji_yun_ying_pc/lanjiali_report/test_school_expense.py" afterDir="false" /> <change beforePath="$PROJECT_DIR$/script/ji_yun_ying_pc/lanjiali_report/test_school_expense.py" beforeDir="false" afterPath="$PROJECT_DIR$/script/ji_yun_ying_pc/lanjiali_report/test_school_expense.py" afterDir="false" />
</list> </list>
<option name="SHOW_DIALOG" value="false" /> <option name="SHOW_DIALOG" value="false" />
...@@ -255,7 +255,14 @@ ...@@ -255,7 +255,14 @@
<option name="project" value="LOCAL" /> <option name="project" value="LOCAL" />
<updated>1619611092963</updated> <updated>1619611092963</updated>
</task> </task>
<option name="localTasksCounter" value="10" /> <task id="LOCAL-00010" summary="校区费用预警-查询">
<created>1619697582572</created>
<option name="number" value="00010" />
<option name="presentableId" value="LOCAL-00010" />
<option name="project" value="LOCAL" />
<updated>1619697582572</updated>
</task>
<option name="localTasksCounter" value="11" />
<servers /> <servers />
</component> </component>
<component name="Vcs.Log.Tabs.Properties"> <component name="Vcs.Log.Tabs.Properties">
...@@ -279,7 +286,8 @@ ...@@ -279,7 +286,8 @@
<MESSAGE value="学生费用预警查询-学生信息对比" /> <MESSAGE value="学生费用预警查询-学生信息对比" />
<MESSAGE value="校区费用预警查询" /> <MESSAGE value="校区费用预警查询" />
<MESSAGE value="学生费用预警查询-分页" /> <MESSAGE value="学生费用预警查询-分页" />
<option name="LAST_COMMIT_MESSAGE" value="学生费用预警查询-分页" /> <MESSAGE value="校区费用预警-查询" />
<option name="LAST_COMMIT_MESSAGE" value="校区费用预警-查询" />
</component> </component>
<component name="XDebuggerManager"> <component name="XDebuggerManager">
<breakpoint-manager> <breakpoint-manager>
......
...@@ -3,7 +3,7 @@ import os ...@@ -3,7 +3,7 @@ import os
if __name__ == '__main__': if __name__ == '__main__':
run_config = [ run_config = [
"-s", "./script/ji_yun_ying_pc/lanjiali_report/test_school_expense.py::Test_select_school_expense_warning::test_schoolExtend_total", "-s", "./script/ji_yun_ying_pc/lanjiali_report/test_school_expense.py",
"--alluredir", "./report/xml", "--alluredir", "./report/xml",
"--host", "http://192.168.32.31", "--host", "http://192.168.32.31",
"--account", "b", "--account", "b",
......
...@@ -17,8 +17,8 @@ import pytest ...@@ -17,8 +17,8 @@ import pytest
@allure.feature("预警报表-学员费用预警查询") @allure.feature("预警报表-学员费用预警查询")
class Test_select_student_expense: class Test_select_student_expense:
@allure.story("学生费用预警查询") @allure.story("学生费用预警查询-关键字查询")
@allure.step("学生费用预警查询-关键字筛选") @allure.title("学生费用预警查询-关键字筛选")
@pytest.mark.parametrize("keyword", keywords) @pytest.mark.parametrize("keyword", keywords)
def test_keywords_search(self,keyword): def test_keywords_search(self,keyword):
keyword_value = keyword.get("keyword") keyword_value = keyword.get("keyword")
...@@ -49,10 +49,8 @@ class Test_select_student_expense: ...@@ -49,10 +49,8 @@ class Test_select_student_expense:
result = public_asserts.assert_res_field_equal_value(studentphone_list,keyword_value) result = public_asserts.assert_res_field_equal_value(studentphone_list,keyword_value)
pytest.assume(result) pytest.assume(result)
@allure.story("学生费用预警查询-年份筛选")
@allure.step("学生费用预警查询-年份筛选")
@pytest.mark.parametrize("year",[select_year()]) @pytest.mark.parametrize("year",[select_year()])
@allure.step("学生费用预警查询-年份筛选")
def test_year_screen(self,year): def test_year_screen(self,year):
data = { data = {
"pageNum": 1, "pageNum": 1,
...@@ -68,10 +66,8 @@ class Test_select_student_expense: ...@@ -68,10 +66,8 @@ class Test_select_student_expense:
result = public_asserts.assert_res_field_equal_value(years,year) result = public_asserts.assert_res_field_equal_value(years,year)
pytest.assume(result) pytest.assume(result)
@allure.story('学生费用预警-期段筛选')
@allure.step('学生费用预警-期段筛选')
@pytest.mark.parametrize( "term",[select_term()]) @pytest.mark.parametrize( "term",[select_term()])
@allure.step("学生费用预警查询-期段筛选")
def test_period_screen(self,term): def test_period_screen(self,term):
data = { data = {
"pageNum": 1, "pageNum": 1,
...@@ -87,10 +83,8 @@ class Test_select_student_expense: ...@@ -87,10 +83,8 @@ class Test_select_student_expense:
result = public_asserts.assert_res_field_equal_value(terms,term) result = public_asserts.assert_res_field_equal_value(terms,term)
pytest.assume(result) pytest.assume(result)
@allure.story("学生费用预警-学生状态筛选")
@allure.step("学生费用预警-学生状态筛选")
@pytest.mark.parametrize("statuses",student_statuses) @pytest.mark.parametrize("statuses",student_statuses)
@allure.step("学生费用预警查询-学生状态筛选")
def test_student_status(self,statuses): def test_student_status(self,statuses):
status_value = statuses['status'] status_value = statuses['status']
status_meaning = statuses['meaning'] status_meaning = statuses['meaning']
...@@ -118,9 +112,8 @@ class Test_select_student_expense: ...@@ -118,9 +112,8 @@ class Test_select_student_expense:
result = public_asserts.assert_res_field_in_list(student_status, status_value) result = public_asserts.assert_res_field_in_list(student_status, status_value)
pytest.assume(result) pytest.assume(result)
@allure.step('学生费用预警-年级筛选') @allure.story('学生费用预警-年级筛选')
@pytest.mark.parametrize("grade",grades) @pytest.mark.parametrize("grade",grades)
@allure.step("学生费用预警查询-年级筛选")
def test_select_grade(self,grade): def test_select_grade(self,grade):
data = { data = {
"pageNum": 1, "pageNum": 1,
...@@ -146,9 +139,8 @@ class Test_select_student_expense: ...@@ -146,9 +139,8 @@ class Test_select_student_expense:
result = public_asserts.assert_res_field_equal_value(grade_list,'4年级') result = public_asserts.assert_res_field_equal_value(grade_list,'4年级')
pytest.assume(result) pytest.assume(result)
@allure.step('学生费用预警-学科筛选') @allure.title('学生费用预警-学科筛选')
@pytest.mark.parametrize("subject", subjects) @pytest.mark.parametrize("subject", subjects)
@allure.step("学生费用预警查询-学科筛选")
def test_select_subject(self,subject): def test_select_subject(self,subject):
data = { data = {
"pageNum": 1, "pageNum": 1,
...@@ -178,9 +170,8 @@ class Test_select_student_expense: ...@@ -178,9 +170,8 @@ class Test_select_student_expense:
result = public_asserts.assert_res_field_equal_value(subject_list,subject) result = public_asserts.assert_res_field_equal_value(subject_list,subject)
pytest.assume(result) pytest.assume(result)
@allure.step("学生费用预警-班型筛选") @allure.story("学生费用预警-班型筛选")
@pytest.mark.parametrize("class_types",classTypes) @pytest.mark.parametrize("class_types",classTypes)
@allure.step("学生费用预警查询-班型筛选")
def test_select_classTypes(self,class_types): def test_select_classTypes(self,class_types):
class_types_value = class_types['classType'] class_types_value = class_types['classType']
classtype_name = class_types['classType_name'] classtype_name = class_types['classType_name']
...@@ -214,8 +205,7 @@ class Test_select_student_expense: ...@@ -214,8 +205,7 @@ class Test_select_student_expense:
pytest.assume(result) pytest.assume(result)
@allure.step("学生费用预警-组合筛选") @allure.story("学生费用预警-组合筛选")
@allure.step("学生费用预警查询-组合筛选")
def test_select_all(self): def test_select_all(self):
data = { data = {
"pageSize": 10, "pageSize": 10,
...@@ -230,6 +220,10 @@ class Test_select_student_expense: ...@@ -230,6 +220,10 @@ class Test_select_student_expense:
"schoolAreaIds": school_areas "schoolAreaIds": school_areas
} }
res = report_finance_student_expense_warning_post(header= jyy_header,body= data) res = report_finance_student_expense_warning_post(header= jyy_header,body= data)
if res['data']['list'] == []:
assert res['msg'] == '成功'
assert res['code'] == 0
else:
#校验名字 #校验名字
studentName_list = jsonpath.jsonpath(res,"$.data.list..studentName") studentName_list = jsonpath.jsonpath(res,"$.data.list..studentName")
keyword_res = public_asserts.assert_res_field_contain_value(studentName_list,'蓝') keyword_res = public_asserts.assert_res_field_contain_value(studentName_list,'蓝')
...@@ -260,7 +254,7 @@ class Test_select_student_expense: ...@@ -260,7 +254,7 @@ class Test_select_student_expense:
pytest.assume(classType_res) pytest.assume(classType_res)
@allure.step("学生费用预警-列表数据汇总") @allure.story("学生费用预警-列表数据汇总")
def test_studentExtend_total(self): def test_studentExtend_total(self):
data = { data = {
...@@ -356,7 +350,7 @@ class Test_select_student_expense: ...@@ -356,7 +350,7 @@ class Test_select_student_expense:
assert round(total_remainAmount[0], 2) == sum_remainAmount assert round(total_remainAmount[0], 2) == sum_remainAmount
@allure.step("学生费用预警-查看学生信息") @allure.story("学生费用预警-查看学生信息")
def test_select_stuinfo(self): def test_select_stuinfo(self):
data = { data = {
"pageNum": 1, "pageNum": 1,
...@@ -378,7 +372,7 @@ class Test_select_student_expense: ...@@ -378,7 +372,7 @@ class Test_select_student_expense:
student_name = student_res['data']['studentName'] student_name = student_res['data']['studentName']
assert studentname_list[0] == student_name assert studentname_list[0] == student_name
@allure.step("学生费用预警-分页") @allure.story("学生费用预警-分页判断")
def test_page(self): def test_page(self):
data = { data = {
"pageNum": 1, "pageNum": 1,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment