File: tbl-row-props.feature

package info (click to toggle)
python-docx 1.2.0%2Bdfsg-1~exp1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 7,216 kB
  • sloc: xml: 25,323; python: 23,414; makefile: 175
file content (74 lines) | stat: -rw-r--r-- 2,188 bytes parent folder | download | duplicates (2)
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
Feature: Get and set table row properties
  In order to format a table row to my requirements
  As a developer using python-docx
  I need a way to get and set the properties of a table row


  Scenario Outline: Get Row.grid_cols_after
    Given a table row ending with <count> empty grid columns
     Then row.grid_cols_after is <count>

    Examples: Row.grid_cols_after value cases
      | count |
      | 0     |
      | 1     |
      | 2     |


  Scenario Outline: Get Row.grid_cols_before
    Given a table row starting with <count> empty grid columns
     Then row.grid_cols_before is <count>

    Examples: Row.grid_cols_before value cases
      | count |
      | 0     |
      | 1     |
      | 3     |


  Scenario Outline: Get Row.height_rule
    Given a table row having height rule <state>
     Then row.height_rule is <value>

    Examples: Row.height_rule value cases
      | state               | value    |
      | no explicit setting | None     |
      | automatic           | AUTO     |
      | at least            | AT_LEAST |


  Scenario Outline: Set Row.height_rule
    Given a table row having height rule <state>
     When I assign <value> to row.height_rule
     Then row.height_rule is <value>

    Examples: Row.height_rule assignment cases
      | state               | value    |
      | no explicit setting | AUTO     |
      | automatic           | AT_LEAST |
      | at least            | None     |
      | no explicit setting | None     |


  Scenario Outline: Get Row.height
    Given a table row having height of <state>
     Then row.height is <value>

    Examples: Row.height value cases
      | state               | value   |
      | no explicit setting | None    |
      | 2 inches            | 1828800 |
      | 3 inches            | 2743200 |


  Scenario Outline: Set row height
    Given a table row having height of <state>
     When I assign <value> to row.height
     Then row.height is <value>

    Examples: Row.height assignment cases
      | state               | value   |
      | no explicit setting | 1828800 |
      | 2 inches            | 2743200 |
      | 3 inches            | None    |
      | no explicit setting | None    |