本文為英文版的機器翻譯版本,如內容有任何歧義或不一致之處,概以英文版為準。
建立組態檔案
您的測試套件必須包含下列必要的組態檔案:
必要檔案
suite.json
-
包含測試套件的相關資訊。請參閱 設定 suite.json。
group.json
-
包含測試群組的相關資訊。您必須為測試套件中的每個測試群組建立
group.json
檔案。請參閱 設定 group.json。 test.json
-
包含測試案例的相關資訊。您必須為測試套件中的每個測試案例建立
test.json
檔案。請參閱 設定 test.json。
-
在
MyTestSuite_1.0.0/suite
資料夾中,建立具有下列結構suite.json
的檔案:{ "id": "MyTestSuite_1.0.0", "title": "My Test Suite", "details": "This is my test suite.", "userDataRequired": false }
-
在
MyTestSuite_1.0.0/myTestGroup
資料夾中,建立具有下列結構group.json
的檔案:{ "id": "MyTestGroup", "title": "My Test Group", "details": "This is my test group.", "optional": false }
-
在
MyTestSuite_1.0.0/myTestGroup/myTestCase
資料夾中,建立具有下列結構test.json
的檔案:{ "id": "MyTestCase", "title": "My Test Case", "details": "This is my test case.", "execution": { "timeout": 300000, "linux": { "cmd": "python3", "args": [ "myTestCase.py" ] }, "mac": { "cmd": "python3", "args": [ "myTestCase.py" ] }, "win": { "cmd": "python3", "args": [ "myTestCase.py" ] } } }
資料夾的目錄樹狀目錄現在MyTestSuite_1.0.0
應如下所示:
MyTestSuite_1.0.0 └── suite ├── suite.json └── myTestGroup ├── group.json └── myTestCase └── test.json