mirror of
https://github.com/httprunner/httprunner.git
synced 2026-09-06 07:57:27 +08:00
update: httprunner make v4
This commit is contained in:
@@ -37,19 +37,6 @@ func (c *ConverterJSON) ToJSON() (string, error) {
|
||||
return jsonPath, nil
|
||||
}
|
||||
|
||||
func (c *ConverterJSON) ToJSONTemp() (string, error) {
|
||||
testCase, err := c.makeTestCaseTemp()
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
jsonPath := c.converter.genOutputPath(suffixJSON)
|
||||
err = builtin.Dump2JSON(testCase, jsonPath)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
return jsonPath, nil
|
||||
}
|
||||
|
||||
func (c *ConverterJSON) ToYAML() (string, error) {
|
||||
testCase, err := c.makeTestCase()
|
||||
if err != nil {
|
||||
@@ -91,19 +78,7 @@ func (c *ConverterJSON) makeTestCase() (*hrp.TCase, error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
err = tCase.MakeCompat2GoEngine()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return tCase, nil
|
||||
}
|
||||
|
||||
func (c *ConverterJSON) makeTestCaseTemp() (*hrp.TCase, error) {
|
||||
tCase, err := makeTestCaseFromJSONYAML(c)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
err = tCase.MakeCompat2PyEngine()
|
||||
err = tCase.MakeCompat()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user