@@ -17,7 +17,7 @@ import { Common } from '../../../client/common/utils/localize';
17
17
import * as telemetry from '../../../client/telemetry' ;
18
18
import { EventName } from '../../../client/telemetry/constants' ;
19
19
20
- suite ( 'Interpreters - Interpreter Selection Tip ' , ( ) => {
20
+ suite ( 'Join Mailing list Prompt Tests ' , ( ) => {
21
21
let joinMailingList : JoinMailingListPrompt ;
22
22
let appShell : IApplicationShell ;
23
23
let storage : IPersistentState < boolean > ;
@@ -74,6 +74,7 @@ suite('Interpreters - Interpreter Selection Tip', () => {
74
74
75
75
await joinMailingList . activate ( ) ;
76
76
77
+ assert . ok ( sendTelemetryStub . calledWithExactly ( EventName . JOIN_MAILING_LIST_PROMPT_DISPLAYED ) ) ;
77
78
verify ( appShell . showInformationMessage ( anything ( ) , Common . bannerLabelYes ( ) , Common . bannerLabelNo ( ) ) ) . once ( ) ;
78
79
verify ( storage . updateValue ( true ) ) . once ( ) ;
79
80
} ) ;
@@ -86,6 +87,7 @@ suite('Interpreters - Interpreter Selection Tip', () => {
86
87
87
88
await joinMailingList . activate ( ) ;
88
89
90
+ assert . ok ( sendTelemetryStub . calledWithExactly ( EventName . JOIN_MAILING_LIST_PROMPT_DISPLAYED ) ) ;
89
91
verify ( appShell . showInformationMessage ( anything ( ) , Common . bannerLabelYes ( ) , Common . bannerLabelNo ( ) ) ) . once ( ) ;
90
92
verify ( storage . updateValue ( true ) ) . once ( ) ;
91
93
} ) ;
@@ -98,6 +100,7 @@ suite('Interpreters - Interpreter Selection Tip', () => {
98
100
99
101
await joinMailingList . activate ( ) ;
100
102
103
+ assert . ok ( sendTelemetryStub . calledWithExactly ( EventName . JOIN_MAILING_LIST_PROMPT_DISPLAYED ) ) ;
101
104
verify ( appShell . showInformationMessage ( anything ( ) , Common . bannerLabelYes ( ) , Common . bannerLabelNo ( ) ) ) . once ( ) ;
102
105
verify ( storage . updateValue ( true ) ) . once ( ) ;
103
106
} ) ;
@@ -113,6 +116,7 @@ suite('Interpreters - Interpreter Selection Tip', () => {
113
116
114
117
await joinMailingList . activate ( ) ;
115
118
119
+ assert . ok ( sendTelemetryStub . calledWithExactly ( EventName . JOIN_MAILING_LIST_PROMPT_DISPLAYED ) ) ;
116
120
verify (
117
121
browserService . launch ( 'https://aka.ms/python-vscode-mailinglist?m=test.sessionId&utm_source=vscode' )
118
122
) . once ( ) ;
@@ -133,6 +137,7 @@ suite('Interpreters - Interpreter Selection Tip', () => {
133
137
134
138
await joinMailingList . activate ( ) ;
135
139
140
+ assert . ok ( sendTelemetryStub . calledWithExactly ( EventName . JOIN_MAILING_LIST_PROMPT_DISPLAYED ) ) ;
136
141
verify ( storage . updateValue ( true ) ) . once ( ) ;
137
142
assert . ok (
138
143
sendTelemetryStub . calledWithExactly ( EventName . JOIN_MAILING_LIST_PROMPT , undefined , { selection : 'No' } )
@@ -149,6 +154,7 @@ suite('Interpreters - Interpreter Selection Tip', () => {
149
154
150
155
await joinMailingList . activate ( ) ;
151
156
157
+ assert . ok ( sendTelemetryStub . calledWithExactly ( EventName . JOIN_MAILING_LIST_PROMPT_DISPLAYED ) ) ;
152
158
verify ( storage . updateValue ( true ) ) . once ( ) ;
153
159
assert . ok (
154
160
sendTelemetryStub . calledWithExactly ( EventName . JOIN_MAILING_LIST_PROMPT , undefined , { selection : undefined } )
0 commit comments