Skip to content
Snippets Groups Projects
Commit 44de0886 authored by Rhys Arkins's avatar Rhys Arkins Committed by GitHub
Browse files

feat: Skip schedules when onboarding (#456)

All PRs/branches will be shown in onboarding even if they have been scheduled for another day or time, providing a "full view" in the onboarding.

Closes #429
parent 997c4efa
No related merge requests found
......@@ -18,6 +18,7 @@ async function findUpgrades(config) {
}
// Check schedule
if (
config.repoIsOnboarded &&
config.schedule &&
config.schedule.length &&
schedule.isScheduledNow(config) === false
......
......@@ -22,6 +22,7 @@ describe('lib/workers/package/index', () => {
expect(res).toMatchObject([]);
});
it('returns empty if package is not scheduled', async () => {
config.repoIsOnboarded = true;
config.schedule = 'some schedule';
schedule.isScheduledNow.mockReturnValueOnce(false);
const res = await pkgWorker.findUpgrades(config);
......@@ -29,6 +30,7 @@ describe('lib/workers/package/index', () => {
expect(npmApi.getDependency.mock.calls.length).toBe(0);
});
it('returns error if no npm dep found', async () => {
config.repoIsOnboarded = true;
config.schedule = 'some schedule';
schedule.isScheduledNow.mockReturnValueOnce(true);
const res = await pkgWorker.findUpgrades(config);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment