0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-13 22:41:32 -05:00

Merge pull request #2052 from Borkason/patch-1

Fix dash-to-triple-hyphen replacement in generateSlug function.
This commit is contained in:
Hannah Wolfe 2014-01-28 12:38:20 -08:00
commit c2bb793c36

View file

@ -243,13 +243,13 @@ describe('Post Model', function () {
it('can generate slugs without duplicate hyphens', function (done) {
var newPost = {
title: 'apprehensive titles have too many spaces ',
title: 'apprehensive titles have too many spaces—and m-dashes — and also n-dashes ',
markdown: 'Test Content 1'
};
PostModel.add(newPost).then(function (createdPost) {
createdPost.get('slug').should.equal('apprehensive-titles-have-too-many-spaces');
createdPost.get('slug').should.equal('apprehensive-titles-have-too-many-spaces-and-m-dashes-and-also-n-dashes');
done();
}).then(null, done);