Browse Source

test: added small changes

pull/7408/head
Ramesh Mane 12 months ago
parent
commit
af5329f9a9
  1. 5
      packages/nc-gui/components/smartsheet/details/Fields.vue
  2. 2
      tests/playwright/pages/Dashboard/Details/FieldsPage.ts

5
packages/nc-gui/components/smartsheet/details/Fields.vue

@ -916,6 +916,7 @@ watch(
toggleVisibility(event.target.checked, viewFieldsMap[field.id]) toggleVisibility(event.target.checked, viewFieldsMap[field.id])
} }
" "
data-testid="nc-field-checkbox"
/> />
<NcCheckbox v-else :disabled="true" class="opacity-0" :checked="true" /> <NcCheckbox v-else :disabled="true" class="opacity-0" :checked="true" />
<SmartsheetHeaderVirtualCellIcon <SmartsheetHeaderVirtualCellIcon
@ -940,13 +941,13 @@ watch(
show-on-truncate-only show-on-truncate-only
> >
<template #title> {{ fieldState(field)?.title || field.title }} </template> <template #title> {{ fieldState(field)?.title || field.title }} </template>
<span> <span data-testid="nc-field-title">
{{ fieldState(field)?.title || field.title }} {{ fieldState(field)?.title || field.title }}
</span> </span>
</NcTooltip> </NcTooltip>
</div> </div>
<div class="flex items-center justify-end gap-1"> <div class="flex items-center justify-end gap-1">
<div class="flex items-center"> <div class="nc-field-status-wrapper flex items-center">
<NcBadge v-if="fieldStatus(field) === 'delete'" color="red" :border="false" class="bg-red-50 text-red-700"> <NcBadge v-if="fieldStatus(field) === 'delete'" color="red" :border="false" class="bg-red-50 text-red-700">
Deleted field Deleted field
</NcBadge> </NcBadge>

2
tests/playwright/pages/Dashboard/Details/FieldsPage.ts

@ -239,6 +239,6 @@ export class FieldsPage extends BasePage {
} }
async getField({ title }: { title: string }) { async getField({ title }: { title: string }) {
return this.fieldListWrapper.locator('> div').locator(`text=${title}`); return this.fieldListWrapper.getByTestId('nc-field-title').locator(`text=${title}`);
} }
} }

Loading…
Cancel
Save