Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
易企天创
zentaoatf
提交
d239da51
Z
zentaoatf
项目概览
易企天创
/
zentaoatf
11 个月 前同步成功
通知
11
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
3
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Z
zentaoatf
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
3
Issue
3
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
d239da51
编写于
7月 31, 2019
作者:
aaronchen2k2k
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
run test script/suite and show results
上级
5bf1b718
变更
18
隐藏空白更改
内联
并排
Showing
18 changed file
with
147 addition
and
119 deletion
+147
-119
src/action/gen.go
src/action/gen.go
+2
-0
src/action/run.go
src/action/run.go
+1
-1
src/atf.go
src/atf.go
+1
-0
src/biz/check.go
src/biz/check.go
+1
-11
src/biz/exe.go
src/biz/exe.go
+7
-6
src/biz/log.go
src/biz/log.go
+90
-0
src/biz/report.go
src/biz/report.go
+7
-22
src/cui.go
src/cui.go
+4
-0
src/script/script.go
src/script/script.go
+4
-0
src/ui/pageImport.go
src/ui/pageImport.go
+1
-1
src/ui/pageMain.go
src/ui/pageMain.go
+8
-8
src/ui/pageSwitch.go
src/ui/pageSwitch.go
+1
-1
src/ui/pageTesting.go
src/ui/pageTesting.go
+10
-10
src/ui/variable.go
src/ui/variable.go
+0
-6
src/utils/constant.go
src/utils/constant.go
+9
-0
src/utils/display.go
src/utils/display.go
+0
-16
xdoc/scripts/tc-200.py
xdoc/scripts/tc-200.py
+0
-36
xdoc/template/python.tpl
xdoc/template/python.tpl
+1
-1
未找到文件。
src/action/gen.go
浏览文件 @
d239da51
...
...
@@ -80,8 +80,10 @@ func DealwithTestCase(tc model.TestCase, langType string, singleFile bool, caseP
srcCode
:=
make
([]
string
,
0
)
steps
=
append
(
steps
,
"@开头的为含验证点的步骤"
)
temp
:=
fmt
.
Sprintf
(
"
\n
%sCODE: 此处编写操作步骤代码
\n
"
,
LangMap
[
langType
][
"commentsTag"
])
srcCode
=
append
(
srcCode
,
temp
)
readme
:=
utils
.
ReadFile
(
"xdoc/template/readme.tpl"
)
+
"
\n
"
stepDisplayMaxWidth
:=
0
...
...
src/action/run.go
浏览文件 @
d239da51
...
...
@@ -13,7 +13,7 @@ func Run(scriptDir string, fileNames []string, langType string) {
scriptDir
=
utils
.
Prefer
.
WorkDir
+
scriptDir
}
LangMap
:=
script
.
GetLangMap
()
LangMap
:=
script
.
LangMap
var
files
[]
string
if
fileNames
!=
nil
&&
len
(
fileNames
)
>
0
{
files
,
_
=
utils
.
GetSpecifiedFiles
(
scriptDir
,
fileNames
)
...
...
src/atf.go
浏览文件 @
d239da51
...
...
@@ -10,6 +10,7 @@ import (
)
func
main
()
{
utils
.
RunFromCui
=
false
flagSets
:=
make
([]
flag
.
FlagSet
,
0
)
var
language
string
...
...
src/biz/check.go
浏览文件 @
d239da51
...
...
@@ -11,7 +11,7 @@ import (
func
CheckResults
(
files
[]
string
,
dir
string
,
langType
string
,
report
*
model
.
TestReport
)
{
fmt
.
Println
(
"
\n
"
)
utils
.
PrintWholeLine
(
utils
.
I118Prt
.
Sprintf
(
"begin_analyse"
),
"="
,
color
.
FgBlue
)
PrintWholeLine
(
utils
.
I118Prt
.
Sprintf
(
"begin_analyse"
),
"="
,
color
.
FgBlue
)
for
_
,
scriptFile
:=
range
files
{
logFile
:=
utils
.
ScriptToLogName
(
dir
,
scriptFile
)
...
...
@@ -99,13 +99,3 @@ func ValidateStep(langType string, expectLines []string, actualLines []string) (
return
stepResult
,
checkpointLogs
}
func
PrintAndLog
(
logs
*
[]
string
,
str
string
)
{
*
logs
=
append
(
*
logs
,
str
)
fmt
.
Println
(
str
)
}
func
PrintAndLogColorLn
(
logs
*
[]
string
,
str
string
,
attr
color
.
Attribute
)
{
*
logs
=
append
(
*
logs
,
str
)
color
.
New
(
attr
)
.
Printf
(
str
+
"
\n
"
)
}
src/biz/exe.go
浏览文件 @
d239da51
...
...
@@ -11,7 +11,7 @@ import (
)
func
ExeScripts
(
files
[]
string
,
dir
string
,
langType
string
,
report
*
model
.
TestReport
)
{
utils
.
PrintWholeLine
(
utils
.
I118Prt
.
Sprintf
(
"start_execution"
,
""
),
"="
,
color
.
FgBlue
)
PrintWholeLine
(
utils
.
I118Prt
.
Sprintf
(
"start_execution"
,
""
),
"="
,
color
.
FgBlue
)
startTime
:=
time
.
Now
()
.
Unix
()
report
.
StartTime
=
startTime
...
...
@@ -20,7 +20,7 @@ func ExeScripts(files []string, dir string, langType string, report *model.TestR
ExeScript
(
file
,
langType
,
dir
)
}
utils
.
PrintWholeLine
(
utils
.
I118Prt
.
Sprintf
(
"end_execution"
,
""
),
"="
,
color
.
FgBlue
)
PrintWholeLine
(
utils
.
I118Prt
.
Sprintf
(
"end_execution"
,
""
),
"="
,
color
.
FgBlue
)
endTime
:=
time
.
Now
()
.
Unix
()
secs
:=
endTime
-
startTime
...
...
@@ -47,18 +47,19 @@ func ExeScript(file string, langType string, dir string) {
fmt
.
Println
(
""
)
msg
:=
utils
.
I118Prt
.
Sprintf
(
"start_case"
,
file
,
startTime
.
Format
(
"2006-01-02 15:04:05"
))
utils
.
PrintWholeLine
(
msg
,
"-"
,
color
.
FgCyan
)
PrintWholeLine
(
msg
,
"-"
,
color
.
FgCyan
)
fmt
.
Println
(
""
)
//
fmt.Println("")
output
:=
utils
.
ExecCommand
(
command
)
utils
.
WriteFile
(
logFile
,
strings
.
Join
(
output
,
""
))
Printt
(
strings
.
Join
(
output
,
""
))
entTime
:=
time
.
Now
()
secs
:=
int64
(
entTime
.
Sub
(
startTime
)
/
time
.
Second
)
msg
=
utils
.
I118Prt
.
Sprintf
(
"end_case"
,
file
,
entTime
.
Format
(
"2006-01-02 15:04:05"
),
secs
)
utils
.
PrintWholeLine
(
msg
,
"-"
,
color
.
FgCyan
)
PrintWholeLine
(
msg
,
"-"
,
color
.
FgCyan
)
fmt
.
Println
(
""
)
//
fmt.Println("")
}
src/biz/log.go
0 → 100644
浏览文件 @
d239da51
package
biz
import
(
"fmt"
"github.com/easysoft/zentaoatf/src/utils"
"github.com/fatih/color"
"io"
"strings"
"unicode/utf8"
)
func
PrintWholeLine
(
msg
string
,
char
string
,
attr
color
.
Attribute
)
{
prefixLen
:=
6
var
postfixLen
int
if
utils
.
RunFromCui
{
maxX
,
_
:=
utils
.
Cui
.
Size
()
postfixLen
=
maxX
-
utils
.
LeftWidth
-
utf8
.
RuneCountInString
(
msg
)
-
8
}
else
{
postfixLen
=
utils
.
Prefer
.
Width
-
utf8
.
RuneCountInString
(
msg
)
-
6
if
postfixLen
<
0
{
// no width in debug mode
postfixLen
=
6
}
}
preFixStr
:=
strings
.
Repeat
(
char
,
prefixLen
)
postFixStr
:=
strings
.
Repeat
(
char
,
postfixLen
)
var
output
io
.
Writer
if
utils
.
RunFromCui
{
output
,
_
=
utils
.
Cui
.
View
(
"main"
)
}
else
{
output
=
color
.
Output
}
clr
:=
color
.
New
(
attr
)
clr
.
Fprintf
(
output
,
fmt
.
Sprintf
(
"%s%s%s
\n
"
,
preFixStr
,
msg
,
postFixStr
))
}
func
PrintAndLog
(
logs
*
[]
string
,
str
string
)
{
*
logs
=
append
(
*
logs
,
str
)
var
output
io
.
Writer
if
utils
.
RunFromCui
{
output
,
_
=
utils
.
Cui
.
View
(
"main"
)
}
else
{
output
=
color
.
Output
}
fmt
.
Fprintf
(
output
,
str
+
"
\n
"
)
}
func
PrintAndLogColorLn
(
logs
*
[]
string
,
str
string
,
attr
color
.
Attribute
)
{
*
logs
=
append
(
*
logs
,
str
)
var
output
io
.
Writer
if
utils
.
RunFromCui
{
output
,
_
=
utils
.
Cui
.
View
(
"main"
)
}
else
{
output
=
color
.
Output
}
clr
:=
color
.
New
(
attr
)
clr
.
Fprintf
(
output
,
str
+
"
\n
"
)
}
func
Printt
(
str
string
)
{
var
output
io
.
Writer
if
utils
.
RunFromCui
{
output
,
_
=
utils
.
Cui
.
View
(
"main"
)
}
else
{
output
=
color
.
Output
}
fmt
.
Fprintf
(
output
,
str
+
"
\n
"
)
}
func
coloredStatus
(
status
string
)
string
{
temp
:=
strings
.
ToLower
(
status
)
switch
temp
{
case
"pass"
:
return
color
.
GreenString
(
utils
.
I118Prt
.
Sprintf
(
temp
))
case
"fail"
:
return
color
.
RedString
(
utils
.
I118Prt
.
Sprintf
(
temp
))
case
"skip"
:
return
color
.
YellowString
(
utils
.
I118Prt
.
Sprintf
(
temp
))
}
return
status
}
src/biz/report.go
浏览文件 @
d239da51
...
...
@@ -26,12 +26,12 @@ func Print(report model.TestReport, workDir string) {
PrintAndLogColorLn
(
&
logs
,
fmt
.
Sprintf
(
" %s: %d"
,
utils
.
I118Prt
.
Sprintf
(
"skip"
),
report
.
Skip
),
color
.
FgYellow
)
for
_
,
cs
:=
range
report
.
Cases
{
str
:=
"
\n
%s %s
\n
"
str
:=
"
\n
%s %s
"
status
:=
cs
.
Status
.
String
()
statusColor
:=
colorStatus
(
status
)
statusColor
:=
color
ed
Status
(
status
)
logs
=
append
(
logs
,
fmt
.
Sprintf
(
str
,
status
,
cs
.
Path
))
fmt
.
Printf
(
str
,
statusColor
,
cs
.
Path
)
Printt
(
fmt
.
Sprintf
(
str
,
statusColor
,
cs
.
Path
)
)
if
len
(
cs
.
Steps
)
>
0
{
count
:=
0
...
...
@@ -42,10 +42,10 @@ func Print(report model.TestReport, workDir string) {
str
:=
" %s%d: %s %s"
status
:=
utils
.
BoolToPass
(
step
.
Status
)
statusColor
:=
colorStatus
(
status
)
statusColor
:=
color
ed
Status
(
status
)
logs
=
append
(
logs
,
fmt
.
Sprintf
(
str
,
utils
.
I118Prt
.
Sprintf
(
"step"
),
step
.
Numb
,
status
,
step
.
Name
))
fmt
.
Printf
(
str
,
utils
.
I118Prt
.
Sprintf
(
"step"
),
step
.
Numb
,
statusColor
,
step
.
Name
+
"
\n
"
)
Printt
(
fmt
.
Sprintf
(
str
,
utils
.
I118Prt
.
Sprintf
(
"step"
),
step
.
Numb
,
statusColor
,
step
.
Name
+
"
\n
"
)
)
count1
:=
0
for
_
,
cp
:=
range
step
.
CheckPoints
{
...
...
@@ -54,10 +54,10 @@ func Print(report model.TestReport, workDir string) {
}
cpStatus
:=
utils
.
BoolToPass
(
step
.
Status
)
cpStatusColor
:=
color
Status
(
cpStatus
)
cpStatusColor
ed
:=
colored
Status
(
cpStatus
)
logs
=
append
(
logs
,
fmt
.
Sprintf
(
" %s%d: %s"
,
utils
.
I118Prt
.
Sprintf
(
"checkpoint"
),
cp
.
Numb
,
utils
.
BoolToPass
(
cp
.
Status
)))
fmt
.
Printf
(
" %s%d: %s"
,
utils
.
I118Prt
.
Sprintf
(
"checkpoint"
),
cp
.
Numb
,
cpStatusColor
)
Printt
(
fmt
.
Sprintf
(
" %s%d: %s"
,
utils
.
I118Prt
.
Sprintf
(
"checkpoint"
),
cp
.
Numb
,
cpStatusColored
)
)
PrintAndLog
(
&
logs
,
fmt
.
Sprintf
(
" %s %s"
,
utils
.
I118Prt
.
Sprintf
(
"expect_result"
),
cp
.
Expect
))
PrintAndLog
(
&
logs
,
fmt
.
Sprintf
(
" %s %s"
,
utils
.
I118Prt
.
Sprintf
(
"actual_result"
),
cp
.
Actual
))
...
...
@@ -74,18 +74,3 @@ func Print(report model.TestReport, workDir string) {
utils
.
WriteFile
(
workDir
+
"/logs/result-"
+
utils
.
DateTimeStrLong
(
time
.
Now
())
+
".txt"
,
strings
.
Join
(
logs
,
"
\n
"
))
}
func
colorStatus
(
status
string
)
string
{
temp
:=
strings
.
ToLower
(
status
)
switch
temp
{
case
"pass"
:
return
color
.
GreenString
(
utils
.
I118Prt
.
Sprintf
(
temp
))
case
"fail"
:
return
color
.
RedString
(
utils
.
I118Prt
.
Sprintf
(
temp
))
case
"skip"
:
return
color
.
YellowString
(
utils
.
I118Prt
.
Sprintf
(
temp
))
}
return
status
}
src/cui.go
浏览文件 @
d239da51
...
...
@@ -9,6 +9,8 @@ import (
)
func
main
()
{
utils
.
RunFromCui
=
true
mock
.
Server
=
mock
.
CreateServer
(
"case-from-prodoct.json"
)
defer
mock
.
Server
.
Close
()
...
...
@@ -20,6 +22,8 @@ func main() {
g
.
Cursor
=
true
g
.
Mouse
=
true
utils
.
Cui
=
g
ui
.
InitMainPage
(
g
)
if
err
:=
g
.
MainLoop
();
err
!=
nil
&&
err
!=
gocui
.
ErrQuit
{
...
...
src/script/script.go
浏览文件 @
d239da51
...
...
@@ -53,3 +53,7 @@ func GetLangMap() map[string]map[string]string {
return
LangMap
}
func
init
()
{
GetLangMap
()
}
src/ui/pageImport.go
浏览文件 @
d239da51
...
...
@@ -72,7 +72,7 @@ func InitImportPage(g *gocui.Gui) error {
singleFileInput
:=
NewRadioWidget
(
g
,
"singleFileInput"
,
left
,
7
,
true
)
ViewMap
[
"import"
]
=
append
(
ViewMap
[
"import"
],
singleFileInput
.
Name
())
buttonX
:=
(
maxX
-
LeftWidth
)
/
2
+
LeftWidth
-
ButtonWidth
buttonX
:=
(
maxX
-
utils
.
LeftWidth
)
/
2
+
utils
.
LeftWidth
-
ButtonWidth
submitInput
:=
NewButtonWidgetAutoWidth
(
g
,
"submitInput"
,
buttonX
,
10
,
"Submit"
,
ImportRequest
)
ViewMap
[
"import"
]
=
append
(
ViewMap
[
"import"
],
submitInput
.
Name
())
...
...
src/ui/pageMain.go
浏览文件 @
d239da51
...
...
@@ -8,17 +8,17 @@ import (
func
InitMainPage
(
g
*
gocui
.
Gui
)
error
{
maxX
,
maxY
:=
g
.
Size
()
if
maxX
<
MinWidth
{
maxX
=
MinWidth
if
maxX
<
utils
.
MinWidth
{
maxX
=
utils
.
MinWidth
}
if
maxY
<
MinHeight
{
maxY
=
MinHeight
if
maxY
<
utils
.
MinHeight
{
maxY
=
utils
.
MinHeight
}
quickBarView
:=
NewPanelWidget
(
g
,
"quickBarView"
,
0
,
0
,
LeftWidth
,
2
,
""
)
quickBarView
:=
NewPanelWidget
(
g
,
"quickBarView"
,
0
,
0
,
utils
.
LeftWidth
,
2
,
""
)
ViewMap
[
"root"
]
=
append
(
ViewMap
[
"root"
],
quickBarView
.
Name
())
sideView
:=
NewPanelWidget
(
g
,
"side"
,
0
,
2
,
LeftWidth
,
maxY
-
3
,
""
)
sideView
:=
NewPanelWidget
(
g
,
"side"
,
0
,
2
,
utils
.
LeftWidth
,
maxY
-
3
,
""
)
ViewMap
[
"root"
]
=
append
(
ViewMap
[
"root"
],
sideView
.
Name
())
x
:=
2
...
...
@@ -28,12 +28,12 @@ func InitMainPage(g *gocui.Gui) error {
x
+=
10
}
mainView
:=
NewPanelWidget
(
g
,
"main"
,
LeftWidth
,
0
,
maxX
-
1
-
LeftWidth
,
maxY
-
10
,
""
)
mainView
:=
NewPanelWidget
(
g
,
"main"
,
utils
.
LeftWidth
,
0
,
maxX
-
1
-
utils
.
LeftWidth
,
maxY
-
10
,
""
)
ViewMap
[
"root"
]
=
append
(
ViewMap
[
"root"
],
mainView
.
Name
())
mainView
.
Editable
=
true
mainView
.
Wrap
=
true
cmdView
:=
NewPanelWidget
(
g
,
"cmd"
,
LeftWidth
,
maxY
-
10
,
maxX
-
1
-
LeftWidth
,
9
,
""
)
cmdView
:=
NewPanelWidget
(
g
,
"cmd"
,
utils
.
LeftWidth
,
maxY
-
10
,
maxX
-
1
-
utils
.
LeftWidth
,
9
,
""
)
ViewMap
[
"root"
]
=
append
(
ViewMap
[
"root"
],
cmdView
.
Name
())
cmdView
.
Autoscroll
=
true
...
...
src/ui/pageSwitch.go
浏览文件 @
d239da51
...
...
@@ -30,7 +30,7 @@ func InitSwitchPage(g *gocui.Gui) error {
return
err
}
buttonX
:=
(
maxX
-
LeftWidth
)
/
2
+
LeftWidth
-
ButtonWidth
buttonX
:=
(
maxX
-
utils
.
LeftWidth
)
/
2
+
utils
.
LeftWidth
-
ButtonWidth
submitInput
:=
NewButtonWidgetAutoWidth
(
g
,
"submitInput"
,
buttonX
,
4
,
"Submit"
,
SwitchWorkDir
)
ViewMap
[
"switch"
]
=
append
(
ViewMap
[
"switch"
],
submitInput
.
Name
())
...
...
src/ui/pageTesting.go
浏览文件 @
d239da51
package
ui
import
(
"fmt"
"github.com/easysoft/zentaoatf/src/action"
"github.com/easysoft/zentaoatf/src/script"
"github.com/easysoft/zentaoatf/src/utils"
"github.com/jroimartin/gocui"
...
...
@@ -82,7 +84,14 @@ func showRunButton(g *gocui.Gui) error {
return
nil
}
func
run
(
g
*
gocui
.
Gui
,
view
*
gocui
.
View
)
error
{
func
run
(
g
*
gocui
.
Gui
,
v
*
gocui
.
View
)
error
{
if
_
,
err
:=
g
.
SetCurrentView
(
"main"
);
err
!=
nil
{
return
err
}
utils
.
PrintToCmd
(
g
,
fmt
.
Sprintf
(
"#atf run -d %s -f %s"
,
utils
.
Prefer
.
WorkDir
,
CurrAsset
))
utils
.
PrintToMain
(
g
,
""
)
action
.
Run
(
utils
.
Prefer
.
WorkDir
,
[]
string
{
CurrAsset
},
""
)
return
nil
}
...
...
@@ -97,15 +106,6 @@ func loadTestAssets() ([]string, []string) {
return
caseFiles
,
suitesFiles
}
func
printSuiteInfo
(
g
*
gocui
.
Gui
,
file
string
)
{
//str := "%s\n Work dir: %s\n Zentao project: %s\n Import type: %s\n Product code: %s\n Language: %s\n " +
// "Independent ExpectResult file: %t"
//str = fmt.Sprintf(str, name, his.ProjectPath, config.Url, config.EntityType, config.EntityVal,
// config.LangType, !config.SingleFile)
//
//utils.PrintToMain(g, str)
}
func
init
()
{
}
...
...
src/ui/variable.go
浏览文件 @
d239da51
...
...
@@ -2,12 +2,6 @@ package ui
import
"sync"
const
(
LeftWidth
=
36
MinWidth
=
130
MinHeight
=
36
)
var
Tabs
[]
string
var
ViewMap
map
[
string
][]
string
...
...
src/utils/constant.go
浏览文件 @
d239da51
package
utils
import
"github.com/jroimartin/gocui"
const
(
PreferenceFile
=
"preferences.yaml"
ConfigFile
=
"conf.yaml"
...
...
@@ -14,4 +16,11 @@ const (
ZhRes
=
"res/messages_zh.json"
GenDir
=
"scripts/"
LeftWidth
=
36
MinWidth
=
130
MinHeight
=
36
)
var
RunFromCui
bool
var
Cui
*
gocui
.
Gui
src/utils/display.go
浏览文件 @
d239da51
package
utils
import
(
"github.com/fatih/color"
"os"
"os/exec"
"regexp"
"strconv"
"strings"
"unicode/utf8"
)
func
InitScreenSize
()
{
...
...
@@ -41,20 +39,6 @@ func InitScreenSize() {
Prefer
.
Height
=
height
}
func
PrintWholeLine
(
msg
string
,
char
string
,
attr
color
.
Attribute
)
{
prefixLen
:=
6
postfixLen
:=
Prefer
.
Width
-
utf8
.
RuneCountInString
(
msg
)
-
6
if
postfixLen
<
0
{
// no width in debug mode
postfixLen
=
6
}
preFixStr
:=
strings
.
Repeat
(
char
,
prefixLen
)
postFixStr
:=
strings
.
Repeat
(
char
,
postfixLen
)
clr
:=
color
.
New
(
attr
)
clr
.
Printf
(
"%s%s%s
\n
"
,
preFixStr
,
msg
,
postFixStr
)
}
func
noWindowsSize
()
(
int
,
int
)
{
cmd
:=
exec
.
Command
(
"stty"
,
"size"
)
cmd
.
Stdin
=
os
.
Stdin
...
...
xdoc/scripts/tc-200.py
已删除
100644 → 0
浏览文件 @
5bf1b718
#-*- coding: UTF-8 -*-
#!/usr/bin/env python
'''
<<TC
caseId: 200
title: 登录失败账号锁定策略
steps: @开头的为含验证点的步骤
step2000 连续输入3次错误的密码
@step2010 第4次尝试登录
group2100 不连续输入3次错误的密码
step2101 输入2次错误的密码
step2102 输入1次正确的密码
step2103 再输入1次错误的密码
@step2104 再输入1次正确的密码
expects:
#
CODE: @step2010期望结果, 可以有多行
#
CODE: @step2104期望结果, 可以有多行
readme:
- 脚本输出日志,同expects章节中#号标注的验证点需保持一致对应
- 脚本中CODE打头的注释需用代码替换
- 参考样例https://github.com/easysoft/zentaoatf/tree/master/xdoc/sample
TC
'''
#CODE: 此处编写操作步骤代码
print
(
"#"
)
# @step2010: 系统提示账号被锁定
#CODE: 输出验证点实际结果
print
(
"#"
)
# @step2104: 登录成功,账号未被锁定
#CODE: 输出验证点实际结果
xdoc/template/python.tpl
浏览文件 @
d239da51
#-*- coding: UTF-8 -*-
#!/usr/bin/env python
#!/usr/bin/env python
3
'''
<
<
TC
caseId:
%
d
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录