Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/client/datascience/notebook/survey.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ export class NotebookSurveyBanner {
if (!this.enabled || this.disabledInCurrentSession) {
return false;
}
const currentDate = new Date();
if (currentDate.getMonth() < 7 && currentDate.getFullYear() <= 2020) {
return false;
}

const data = this.persistentState.createGlobalPersistentState<NotebookSurveyUsageData>(storageKey, {});

const totalActionsInPreviousSessions =
Expand Down
1 change: 1 addition & 0 deletions src/test/datascience/notebook/survey.unit.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ suite('Data Science - NativeNotebook Survey', () => {
shell = mock<IApplicationShell>();
browser = mock<IBrowserService>();
clock = fakeTimers.install();
clock.setSystemTime(new Date(2020, 7, 1)); // Survey will work only after 1st August.
});
async function loadAndActivateExtension() {
const surveyBanner = new NotebookSurveyBanner(instance(shell), instance(stateFactory), instance(browser));
Expand Down