You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 2aedd34
Browse filesBrowse the repository at this point in the historyBrowse files
Dev-3
committed
test: pin the two server-choice states apart on one paint (#2946)
#2945 owns the damaged-file refusal and this card owns a valid file holding an address the
validator refuses. The page test now asserts both directions in the same render: with a saved
fact there is no refusal sentence, and on the refusal page there is no saved line.
Copy file name to clipboardExpand all lines: plugins/social/test/social.test.js
+10-2Lines changed: 10 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -9456,9 +9456,15 @@ test('Settings → Bot Social page: shows server, source and status; the switch
9456
9456
test('#2946: Settings names a saved server the profile cannot use, and says nothing when none was saved', () => {
9457
9457
{
9458
9458
const { plugin, all, text } = clientPlugin([serverView({ saved: { address: 'http://not-allowed.example', problem: 'The address must start with https://' } }), null, null])
assert.ok(row, 'the page names the saved server it could not use')
9461
9462
assert.equal(text(row), 'The server saved here (http://not-allowed.example) cannot be used: The address must start with https://. Using the profile default (https://a.test).')
9463
+
// Same first paint, the other state on this panel (#2945): a damaged file refuses with its own
9464
+
// whole sentence. This view has a saved fact, so that refusal must not be drawn beside it.
9465
+
const paint = text(nodes[0])
9466
+
assert.doesNotMatch(paint, /does not parse as JSON|cannot be read/)
9467
+
assert.doesNotMatch(paint, /Social is not running:/)
9462
9468
}
9463
9469
{
9464
9470
// No saved file, no `saved` fact: the page says nothing extra.
@@ -9470,8 +9476,10 @@ test('#2946: Settings names a saved server the profile cannot use, and says noth
9470
9476
// draws the refusal and no saved-server line — the two states never draw together.
9471
9477
const { plugin, all, text } = clientPlugin([null, 'The Bot Social server chosen in Settings at ./flybot-social-server.json exists but does not parse as JSON.'])
0 commit comments