Updated webhook test snapshots

refs: 717a27c85c
refs: 6380b82793

- The snapshots just needed updating
This commit is contained in:
Hannah Wolfe 2022-10-21 14:33:29 +01:00
parent 717a27c85c
commit 3ab1c418bc
No known key found for this signature in database
GPG Key ID: AB586C3B5AE5C037
2 changed files with 14 additions and 3 deletions

View File

@ -194,7 +194,7 @@ Object {
"tour": null,
"twitter": null,
"updated_at": StringMatching /\\\\d\\{4\\}-\\\\d\\{2\\}-\\\\d\\{2\\}T\\\\d\\{2\\}:\\\\d\\{2\\}:\\\\d\\{2\\}\\\\\\.000Z/,
"url": "http://127.0.0.1:2369/author/joe-bloggs/",
"url": StringMatching /http:\\\\/\\\\/127\\.0\\.0\\.1:2369\\\\/\\\\w\\+\\\\//,
"website": null,
},
],
@ -256,7 +256,7 @@ Object {
"tour": null,
"twitter": null,
"updated_at": StringMatching /\\\\d\\{4\\}-\\\\d\\{2\\}-\\\\d\\{2\\}T\\\\d\\{2\\}:\\\\d\\{2\\}:\\\\d\\{2\\}\\\\\\.000Z/,
"url": "http://127.0.0.1:2369/author/joe-bloggs/",
"url": StringMatching /http:\\\\/\\\\/127\\.0\\.0\\.1:2369\\\\/\\\\w\\+\\\\//,
"website": null,
},
"primary_tag": null,
@ -627,7 +627,6 @@ Object {
"count": Object {
"paid_conversions": 0,
"positive_feedback": 0,
"sentiment": 0,
"signups": 0,
},
"created_at": StringMatching /\\\\d\\{4\\}-\\\\d\\{2\\}-\\\\d\\{2\\}T\\\\d\\{2\\}:\\\\d\\{2\\}:\\\\d\\{2\\}\\\\\\.000Z/,

View File

@ -0,0 +1,12 @@
const handlebars = require('../../../../core/frontend/services/theme-engine/engine').handlebars;
function shouldCompileToExpected(templateString, hash, expected) {
const template = handlebars.compile(templateString);
const result = template(hash);
result.should.eql(expected);
}
module.exports = {
shouldCompileToExpected
};