@@ -10,20 +10,10 @@ import {dataApiHelpersTest} from '../../fixtures/dataApiHelpersTest';
1010import { featureFlagsTest } from '../../fixtures/featureFlagsTest' ;
1111import { loginAnalyticsCloudTest } from '../../fixtures/loginAnalyticsCloudTest' ;
1212import { loginTest } from '../../fixtures/loginTest' ;
13- import { liferayConfig } from '../../liferay.config' ;
1413import getRandomString from '../../utils/getRandomString' ;
15- import { syncAnalyticsCloud } from '../analytics-settings-web/utils/analytics-settings' ;
16- import { faroConfig } from './faro.config' ;
17- import { clickOnLink } from './utils/actions' ;
18- import { switchChannel } from './utils/channel' ;
19- import {
20- ACPage ,
21- navigateTo ,
22- navigateToACPageViaURL ,
23- navigateToACSettingsViaURL ,
24- navigateToACWorkspace ,
25- } from './utils/navigation' ;
26- import { addBreakdownByIndividualAttribute } from './utils/utils' ;
14+ import { faroConfig } from './faro.config' ;
15+ import { clickOnLink } from './utils/actions' ;
16+ import { ACPage , navigateToACSettingsViaURL } from './utils/navigation' ;
2717
2818export const test = mergeTests (
2919 apiHelpersTest ,
@@ -40,7 +30,9 @@ let project;
4030const randomString = getRandomString ( ) ;
4131
4232test . beforeEach ( async ( { apiHelpers} ) => {
43- project = await apiHelpers . jsonWebServicesOSBFaro . createProject ( 'My Project ' + randomString )
33+ project = await apiHelpers . jsonWebServicesOSBFaro . createProject (
34+ 'My Project ' + randomString
35+ ) ;
4436} ) ;
4537
4638test . afterEach ( async ( { apiHelpers} ) => {
7466 ) . toBeVisible ( ) ;
7567
7668 await clickOnLink ( {
77- baseUrl :faroConfig . environment . baseUrl ,
69+ baseUrl : faroConfig . environment . baseUrl ,
7870 name : 'Access our documentation to learn more.' ,
7971 page,
8072 } ) ;
10597 ) . toBeVisible ( ) ;
10698
10799 await clickOnLink ( {
108- baseUrl :faroConfig . environment . baseUrl ,
100+ baseUrl : faroConfig . environment . baseUrl ,
109101 name : 'Access our documentation to learn more.' ,
110102 page,
111103 } ) ;
@@ -145,25 +137,19 @@ test(
145137 projectID : project . groupId ,
146138 } ) ;
147139
148- //await clickOnLink({baseUrl:faroConfig.environment.baseUrl, name: 'canonicalUrl', page});
149-
150140 const tableBodyElement = await page . locator ( 'table tbody' ) ;
151141
152- await expect (
153- tableBodyElement
154- ) . toBeVisible ( ) ;
142+ await expect ( tableBodyElement ) . toBeVisible ( ) ;
155143
156- const elements = await tableBodyElement . locator ( 'td .table-title a' ) . all ( ) ;
144+ const elements = await tableBodyElement
145+ . locator ( 'td .table-title a' )
146+ . all ( ) ;
157147
158148 const href = await elements [ 0 ] . getAttribute ( 'href' ) ;
159149
160150 await page . goto ( `${ faroConfig . environment . baseUrl } ${ href } ` ) ;
161151
162- await expect (
163- page . getByText (
164- 'No Sample Data Found'
165- )
166- ) . toBeVisible ( ) ;
152+ await expect ( page . getByText ( 'No Sample Data Found' ) ) . toBeVisible ( ) ;
167153 await expect (
168154 page . getByText (
169155 'You can come back later and check if there is any data received from your events.Learn more about event tracking'
@@ -174,13 +160,13 @@ test(
174160 ) . toBeVisible ( ) ;
175161
176162 await clickOnLink ( {
177- baseUrl :faroConfig . environment . baseUrl ,
163+ baseUrl : faroConfig . environment . baseUrl ,
178164 name : 'Learn more about event tracking.' ,
179165 page,
180166 } ) ;
181167
182168 await expect ( page ) . toHaveTitle ( 'Definitions - Liferay Learn' ) ;
183-
169+
184170 const header = await page . locator ( 'h2#event-attributes' ) ;
185171
186172 await expect ( header . getByText ( 'Event Attributes' ) ) . toBeVisible ( ) ;
@@ -204,7 +190,7 @@ test(
204190 ) . toBeVisible ( ) ;
205191
206192 await clickOnLink ( {
207- baseUrl :faroConfig . environment . baseUrl ,
193+ baseUrl : faroConfig . environment . baseUrl ,
208194 name : 'Learn how to add custom events on your site.' ,
209195 page,
210196 } ) ;
@@ -232,7 +218,7 @@ test(
232218 ) . toBeVisible ( ) ;
233219
234220 await clickOnLink ( {
235- baseUrl :faroConfig . environment . baseUrl ,
221+ baseUrl : faroConfig . environment . baseUrl ,
236222 name : 'Access our documentation to learn how to manage custom events.' ,
237223 page,
238224 } ) ;
@@ -276,7 +262,7 @@ test(
276262 ) . toBeVisible ( ) ;
277263
278264 await clickOnLink ( {
279- baseUrl :faroConfig . environment . baseUrl ,
265+ baseUrl : faroConfig . environment . baseUrl ,
280266 name : 'Access our documentation to learn more.' ,
281267 page,
282268 } ) ;
@@ -288,8 +274,7 @@ test(
288274 const element = await page . locator ( 'a#data-control-and-privacy' ) ;
289275
290276 await expect (
291- element
292- . getByText ( 'Data Control and Privacy' )
277+ element . getByText ( 'Data Control and Privacy' )
293278 ) . toBeVisible ( ) ;
294279 } ) ;
295280 }
0 commit comments