index.test.js 492 B

1234567891011121314151617
  1. const pug = require('../../');
  2. test('#2436 - block with a same name extends from the same layout in nesting', () => {
  3. const output = pug.renderFile(
  4. __dirname + '/issue1.pug',
  5. {pretty: true}
  6. );
  7. expect(output).toMatchSnapshot();
  8. });
  9. test('#2436 - block with a same name extends from different layout in nesting', () => {
  10. const output = pug.renderFile(
  11. __dirname + '/issue2.pug',
  12. {pretty: true}
  13. );
  14. expect(output).toMatchSnapshot();
  15. });