File tree Expand file tree Collapse file tree 2 files changed +5
-9
lines changed Expand file tree Collapse file tree 2 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -141,7 +141,7 @@ type ParseParams = {
141
141
} ;
142
142
143
143
export function parse ( params : ParseParams ) : any {
144
- const mdContent : TutorialFrame = parseMdContent ( params . text ) ;
144
+ const mdContent : TutorialFrame = parseMdContent ( params . text + "\n\n" ) ;
145
145
146
146
const parsed : Partial < T . Tutorial > = {
147
147
version : params . skeleton . version ,
Original file line number Diff line number Diff line change @@ -1189,7 +1189,7 @@ The first step
1189
1189
expect ( result . levels ) . toEqual ( expected . levels ) ;
1190
1190
} ) ;
1191
1191
1192
- it ( "should parse a single hint " , ( ) => {
1192
+ it ( "should parse without spaces at the end " , ( ) => {
1193
1193
const md = `# Title
1194
1194
1195
1195
Description.
@@ -1204,9 +1204,7 @@ The first step
1204
1204
1205
1205
#### HINTS
1206
1206
1207
- - A test with a \`backtick\`
1208
-
1209
- ` ;
1207
+ - A test with a \`backtick\`` ;
1210
1208
const skeleton = {
1211
1209
levels : [
1212
1210
{
@@ -1222,9 +1220,7 @@ The first step
1222
1220
const result = parse ( {
1223
1221
text : md ,
1224
1222
skeleton,
1225
- commits : {
1226
- "1.1:T" : [ "abcdef1" , "123456789" ] ,
1227
- } ,
1223
+ commits : { } ,
1228
1224
} ) ;
1229
1225
const expected = {
1230
1226
summary : {
@@ -1241,7 +1237,7 @@ The first step
1241
1237
id : "1.1" ,
1242
1238
content : "The first step" ,
1243
1239
setup : {
1244
- commits : [ "abcdef1" , "123456789" ] ,
1240
+ commits : [ ] ,
1245
1241
} ,
1246
1242
hints : [ "A test with a `backtick`" ] ,
1247
1243
} ,
You can’t perform that action at this time.
0 commit comments