mirror of
https://github.com/jsdoc/jsdoc.git
synced 2025-12-08 19:46:11 +00:00
JSDoc-specific test functions are now properties of a `jsdoc` global, not a `jasmine` global. Also updates license files to reflect the fact that we no longer vendor anything.
19 lines
680 B
JavaScript
19 lines
680 B
JavaScript
describe('generator functions', () => {
|
|
const docSet = jsdoc.getDocSetFromFile('test/fixtures/generators.js');
|
|
const startsAt0 = docSet.getByLongname('startsAt0')[0];
|
|
const startsAt1 = docSet.getByLongname('startsAt1')[0];
|
|
const startsAt2 = docSet.getByLongname('Generator#startsAt2')[0];
|
|
|
|
it('should flag generator functions', () => {
|
|
expect(startsAt0.generator).toBe(true);
|
|
});
|
|
|
|
it('should flag generator functions assigned to variables', () => {
|
|
expect(startsAt1.generator).toBe(true);
|
|
});
|
|
|
|
it('should flag generator functions that are method definitions', () => {
|
|
expect(startsAt2.generator).toBe(true);
|
|
});
|
|
});
|