feat: saving json data for future use

This commit is contained in:
GitHub Actions
2021-06-24 00:02:40 +02:00
parent cee1906a39
commit 7ceb9cb783
5 changed files with 36 additions and 11 deletions

View File

@@ -38,7 +38,7 @@ import {
apiGetStar,
paginate,
generateMd,
pushNewFile,
pushNewFiles,
} from '../src/helpers';
test('wait should wait', async (t) => {
@@ -97,7 +97,7 @@ test('generateMd should create TOC', async (t) => {
});
test('should push', async (t) => {
await pushNewFile('# title');
await pushNewFiles([{filename: "README.md", data: '# title'}]);
t.true(writeFile.calledWith('README.md', '# title'));
t.true(pull.called);
t.true(add.calledWith('README.md'));