t.yaml 4.6 KB
Newer Older
aaronchen2k2k's avatar
aaronchen2k2k 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104
title: range
desc:
version: 1.0

fields:
#- field: field_text                   # 从一个文件中随机读取。
#  range: res/user.txt:R                   # 相对当前文件路径。
#  postfix: "\t"
#- field: f1
#  range: 1-9
#  postfix: "ttt"
#  loop:  1-3
#
#  - field: field_use_config
#    config: number.yaml
#    postfix: "\t"

#  - field: field_text       # 从一个文件中随机读取。
#    range: user.txt:R       # 相对当前文件路径。
#    postfix: "\t"
#  - field: f1     # 区间
#    range: 1-3   # 1,2,3,10...
#    postfix: "\t"
#
#  - field: field_use_ranges_medium
#    from: zentao.number.v1.yaml
#    use: medium{5}                    # 使用该文件中定义的medium分组。
#    postfix: "\t"
#
#  - field: field_use_instance      # 引用其他的定义文件,该文件定义了多个实例。
#    from: ip.v1.yaml               # yaml/ip/v1.yaml
#    use: privateB{3},privateC{6:2} # 使用该文件中定义的2个实例,privateB取3行,privateC取6行(前3个值各重复2次)。
#    postfix: "\t"
#
#  - field: part1
#    from: name.cnreal.v1.yaml
#    use: two

#  - field: telephone_china
#    from: phone.v1.yaml
#    use: telephone_china
#    postfix: "\t"
#
#  - field: telephone_china_with_city_code
#    from: phone.v1.yaml
#    use: telephone_china_with_city_code
#    postfix: "\t"
#
#  - field: telephone_china_with_country_code
#    from: phone.v1.yaml
#    use: telephone_china_with_country_code
#    postfix: "\t"
#
#  - field: telephone_400
#    from: phone.v1.yaml
#    use: telephone_400
#    postfix: "\t"
#
#  - field: telephone_service
#    from: phone.v1.yaml
#    use: telephone_service
#    postfix: "\t"

#  - field: cellphone
#    from: phone.v1.yaml
#    use: cellphone
#    postfix: "\t"
#
#  - field: qq
#    from: phone.v1.yaml
#    use: qq
#    postfix: "\t"
#
#  - field: field_creditcard
#    format: "credit_card('amex')"
#    postfix: "\t"
#
#  - field: field_idcard
#    format: "id_card()"
#    postfix: "\t"

#  - field: first
#    range: tt.yaml{5}  # 注意此处{10}为取10条记录,非重复语法。
#    rand: true
#    prefix: "("
#    postfix: ")"

#  - field: field_use_excel
#    from: areacode.v1.city
#    select: code||'-'||city
#    where: id > 1
#    rand: true
#    postfix: "\t"
#
#  - field: field_use_excel2
#    from: areacode.v1.country
#    select: code||'-'||chinese_name
#    where: id > 1
#    rand: true
#    postfix: "\t"
#
#- field: f11
#  range: 1-9

105 106 107 108 109 110 111 112 113 114 115 116 117
#- field: join_false
#  mode: r
#  postfix: "\t"
#  fields:
#    - field: child1
#      range: A-C
#      prefix: PART1_
#      postfix: ' | '
#
#    - field: child2
#      range: 0-9
#    - field: child3
#      range: 0-3,a-z
aaronchen2k2k's avatar
aaronchen2k2k 已提交
118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180

#  - field: join_true
#    mode: p
#    join: true
#    fields:
#      - field: child1
#        range: A-C
#        prefix: PART1_
#        postfix: ' | '
#      - field: child2
#        range: a-c
#        prefix: part2_
#      - field: child3
#        fields:
#          - field: child1
#            range: A-F
#            prefix: CHILD1_
#            postfix: ' | '
#          - field: child2
#            range: a-c
#            prefix: CHILD2_

#  - field: f1
#    range: 0-9
#    postfix: "\t"
#
#  - field: f2
#    range: 1-3{3} # 逐个重复,生成类似 a、a、a、b、b、b、c、c、c
#    postfix: "\t"
#  - field: f3
#    range: 1-3{3!} # 迭代重复,生成类似 a、b、c、a、b、c、a、b、c
#    postfix: "\t"
#
#  - field: f4
#    range: a-c{3} # 迭代重复,生成类似 a、b、c、a、b、c、a、b、c
#    postfix: "\t"
#  - field: f5
#    range: a-c{3!} # 迭代重复,生成类似 a、b、c、a、b、c、a、b、c
#    postfix: "\t"
#
#  - field: f6
#    range: 0.01-9
#    postfix: "\t"
#
#  - field: f7
#    range: 0.01-0.03{3}
#    postfix: "\t"
#
#  - field: f8
#    range: 0.01-0.03{3!}
#    postfix: "\t"
#
#  - field: f9
#    range: 0-9:R
#    postfix: "\t"
#
#  - field: f11
#    range: 0.01-9
#    postfix: "\t"
#
#  - field: field_format                 # 通过格式化字符串输出。
#    range: 1-10                         # passwd 1,passwd 2,passwd 3 ... passwd10。
#    format: "passwd%02d"                # 用%02d补零,使密码整体保持8位。
181 182 183 184 185 186 187 188 189 190 191 192 193
#    postfix: "\t"

  - field: time1     # 生成时间数据,以当前时间为准,从一月前到一周后。
    range: "(-1M)-(+1w):60"        # 支持当前时间的运算,Y、M、D、W、h、m、s分别对应年、月、日、周、时、分、秒。
    type: timestamp
    format: "YY/MM/DD hh:mm:ss"
    postfix: "\t"

#  - field: test
#    range: '{"a":1}'
#    postfix: "\t"

#  - field: test
aaronchen2k2k's avatar
aaronchen2k2k 已提交
194
#    format: "binary()"
aaronchen2k2k's avatar
aaronchen2k2k 已提交
195
#    postfix: "\t"