Skip to content

Commit 4c37ee1

Browse files
committed
fix(test): adjust SyncStatus snapshots, cleanup left overs.
Signed-off-by: Max <max@nextcloud.com>
1 parent 24d04c1 commit 4c37ee1

2 files changed

Lines changed: 5 additions & 11 deletions

File tree

src/components/Editor/DocumentStatus/SyncStatus.vue

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
<script>
1616
17-
import { ERROR_TYPE, IDLE_TIMEOUT } from '../../../services/SyncService.js'
17+
import { ERROR_TYPE } from '../../../services/SyncService.js'
1818
import { NcNoteCard } from '@nextcloud/vue'
1919
2020
export default {
@@ -39,12 +39,6 @@ export default {
3939
},
4040
},
4141
42-
data() {
43-
return {
44-
IDLE_TIMEOUT,
45-
}
46-
},
47-
4842
computed: {
4943
card() {
5044
if (this.isLoadingError) {
@@ -69,7 +63,7 @@ export default {
6963
if (this.idle) {
7064
return {
7165
type: 'info',
72-
message: t('text', 'You\'ve been disconnected from the server.', { timeout: IDLE_TIMEOUT }),
66+
message: t('text', 'You\'ve been disconnected from the server.')
7367
action: this.reconnect,
7468
actionLabel: t('text', 'Reconnect'),
7569
}

src/tests/components/__snapshots__/SyncStatus.spec.js.snap

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,19 @@
22

33
exports[`renders hasConnectionIssue 1`] = `
44
"<ncnotecard-stub data-v-56029fad="" type="warning" heading="" text="">
5-
<p data-v-56029fad=""> Document could not be loaded. Please check your internet connection. <a data-v-56029fad="" class="button primary">Reconnect</a></p>
5+
<p data-v-56029fad=""> The document could not be loaded. Please check your internet connection. <a data-v-56029fad="" class="button primary">Reconnect</a></p>
66
</ncnotecard-stub>"
77
`;
88

99
exports[`renders idle 1`] = `
1010
"<ncnotecard-stub data-v-56029fad="" type="info" heading="" text="">
11-
<p data-v-56029fad=""> Document idle for {timeout} minutes, click to continue editing <a data-v-56029fad="" class="button primary">Reconnect</a></p>
11+
<p data-v-56029fad=""> You've been disconnected from the server. <a data-v-56029fad="" class="button primary">Reconnect</a></p>
1212
</ncnotecard-stub>"
1313
`;
1414

1515
exports[`renders sync error 0 1`] = `
1616
"<ncnotecard-stub data-v-56029fad="" type="warning" heading="" text="">
17-
<p data-v-56029fad=""> Document has been changed outside of the editor. The changes cannot be applied
17+
<p data-v-56029fad=""> The file was overwritten. Your current changes cannot be auto-saved. Please choose how to proceed.
1818
<!---->
1919
</p>
2020
</ncnotecard-stub>"

0 commit comments

Comments
 (0)