Skip to content

Commit fad3045

Browse files
alessiodionisidetro
authored andcommitted
Fix render newline and pass tests
1 parent c0143dd commit fad3045

File tree

2 files changed

+10
-12
lines changed

2 files changed

+10
-12
lines changed

schemamd/render.go

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -523,12 +523,7 @@ func writeNestedAttributeChildren(w io.Writer, parents []string, nestedAttribute
523523
}
524524
}
525525

526-
_, err := io.WriteString(w, "\n")
527-
if err != nil {
528-
return err
529-
}
530-
531-
err = writeNestedTypes(w, nestedTypes)
526+
err := writeNestedTypes(w, nestedTypes)
532527
if err != nil {
533528
return err
534529
}

schemamd/testdata/awscc_acmpca_certificate.md

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,23 +49,26 @@ Optional:
4949
<a id="nestedatt--api_passthrough--extensions--certificate_policies"></a>
5050
### Nested Schema for `api_passthrough.extensions.certificate_policies`
5151

52-
Optional:
52+
Required:
5353

5454
- `cert_policy_id` (String) String that contains X.509 ObjectIdentifier information.
55+
56+
Optional:
57+
5558
- `policy_qualifiers` (Attributes List) (see [below for nested schema](#nestedatt--api_passthrough--extensions--certificate_policies--policy_qualifiers))
5659

5760
<a id="nestedatt--api_passthrough--extensions--certificate_policies--policy_qualifiers"></a>
5861
### Nested Schema for `api_passthrough.extensions.certificate_policies.policy_qualifiers`
5962

60-
Optional:
63+
Required:
6164

6265
- `policy_qualifier_id` (String)
6366
- `qualifier` (Attributes) Structure that contains a X.509 policy qualifier. (see [below for nested schema](#nestedatt--api_passthrough--extensions--certificate_policies--policy_qualifiers--qualifier))
6467

6568
<a id="nestedatt--api_passthrough--extensions--certificate_policies--policy_qualifiers--qualifier"></a>
6669
### Nested Schema for `api_passthrough.extensions.certificate_policies.policy_qualifiers.qualifier`
6770

68-
Optional:
71+
Required:
6972

7073
- `cps_uri` (String)
7174

@@ -135,7 +138,7 @@ Optional:
135138
<a id="nestedatt--api_passthrough--extensions--subject_alternative_names--edi_party_name"></a>
136139
### Nested Schema for `api_passthrough.extensions.subject_alternative_names.uniform_resource_identifier`
137140

138-
Optional:
141+
Required:
139142

140143
- `name_assigner` (String)
141144
- `party_name` (String)
@@ -144,7 +147,7 @@ Optional:
144147
<a id="nestedatt--api_passthrough--extensions--subject_alternative_names--other_name"></a>
145148
### Nested Schema for `api_passthrough.extensions.subject_alternative_names.uniform_resource_identifier`
146149

147-
Optional:
150+
Required:
148151

149152
- `type_id` (String) String that contains X.509 ObjectIdentifier information.
150153
- `value` (String)
@@ -177,7 +180,7 @@ Optional:
177180
<a id="nestedatt--validity_not_before"></a>
178181
### Nested Schema for `validity_not_before`
179182

180-
Optional:
183+
Required:
181184

182185
- `type` (String)
183186
- `value` (Number)

0 commit comments

Comments
 (0)