-
Notifications
You must be signed in to change notification settings - Fork 546
/
Copy pathshp-graphicframe.feature
50 lines (34 loc) · 1.58 KB
/
shp-graphicframe.feature
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
Feature: GraphicFrame properties and methods
In order to operate on a GraphicFrame shape
As a developer using python-pptx
I need properties and methods on GraphicFrame
Scenario: GraphicFrame.chart
Given a GraphicFrame object containing a chart as shape
Then shape.chart is a Chart object
Scenario Outline: GraphicFrame.has_chart
Given a GraphicFrame object containing a <graphical-object> as shape
Then shape.has_chart is <value>
Examples: Shape types
| graphical-object | value |
| chart | True |
| table | False |
Scenario: GraphicFrame.ole_format
Given a GraphicFrame object containing an OLE object as shape
Then shape.ole_format is an _OleFormat object
Scenario Outline: GraphicFrame.shape_type
Given a GraphicFrame object containing <graphical-object> as shape
Then shape.shape_type == <expected-value>
Examples: Shape types
| graphical-object | expected-value |
| an OLE object | MSO_SHAPE_TYPE.EMBEDDED_OLE_OBJECT |
| a chart | MSO_SHAPE_TYPE.CHART |
| a table | MSO_SHAPE_TYPE.TABLE |
Scenario: _OleFormat.blob
Given an _OleFormat object for an embedded XLSX as ole_format
Then len(ole_format.blob) == 8287
Scenario: _OleFormat.prog_id
Given an _OleFormat object for an embedded XLSX as ole_format
Then ole_format.prog_id == "Excel.Sheet.12"
Scenario: _OleFormat.show_as_icon
Given an _OleFormat object for an OLE object as ole_format
Then ole_format.show_as_icon is True