mirror of
https://github.com/discourse/discourse.git
synced 2025-03-10 00:35:44 +08:00
correct failing test
This commit is contained in:
parent
6a01a371ee
commit
4194886b62
@ -60,7 +60,7 @@
|
|||||||
<div class="controls">
|
<div class="controls">
|
||||||
{{#if currentUser}}
|
{{#if currentUser}}
|
||||||
<section class='field'>
|
<section class='field'>
|
||||||
<label>{{input type="checkbox" class="in-likes" checked=searchedTerms.special.in.title}} {{i18n "search.advanced.filters.title"}}</label>
|
<label>{{input type="checkbox" class="in-title" checked=searchedTerms.special.in.title}} {{i18n "search.advanced.filters.title"}}</label>
|
||||||
<label>{{input type="checkbox" class="in-likes" checked=searchedTerms.special.in.likes}} {{i18n "search.advanced.filters.likes"}}</label>
|
<label>{{input type="checkbox" class="in-likes" checked=searchedTerms.special.in.likes}} {{i18n "search.advanced.filters.likes"}}</label>
|
||||||
<label>{{input type="checkbox" class="in-private" checked=searchedTerms.special.in.private}} {{i18n "search.advanced.filters.private"}}</label>
|
<label>{{input type="checkbox" class="in-private" checked=searchedTerms.special.in.private}} {{i18n "search.advanced.filters.private"}}</label>
|
||||||
<label>{{input type="checkbox" class="in-seen" checked=searchedTerms.special.in.seen}} {{i18n "search.advanced.filters.seen"}}</label>
|
<label>{{input type="checkbox" class="in-seen" checked=searchedTerms.special.in.seen}} {{i18n "search.advanced.filters.seen"}}</label>
|
||||||
|
@ -175,16 +175,23 @@ QUnit.test("update category through advanced search ui", assert => {
|
|||||||
// });
|
// });
|
||||||
// });
|
// });
|
||||||
// });
|
// });
|
||||||
|
//
|
||||||
|
QUnit.test("update in:title filter through advanced search ui", async assert => {
|
||||||
|
await visit("/search");
|
||||||
|
await fillIn('.search-query', 'none');
|
||||||
|
await click('.search-advanced-options .in-title');
|
||||||
|
|
||||||
QUnit.test("update in:likes filter through advanced search ui", assert => {
|
assert.ok(exists('.search-advanced-options .in-title:checked'), 'has "in title" populated');
|
||||||
visit("/search");
|
assert.equal(find('.search-query').val(), "none in:title", 'has updated search term to "none in:title"');
|
||||||
fillIn('.search-query', 'none');
|
});
|
||||||
click('.search-advanced-options .in-likes');
|
|
||||||
|
|
||||||
andThen(() => {
|
QUnit.test("update in:likes filter through advanced search ui", async assert => {
|
||||||
assert.ok(exists('.search-advanced-options .in-likes:checked'), 'has "I liked" populated');
|
await visit("/search");
|
||||||
assert.equal(find('.search-query').val(), "none in:likes", 'has updated search term to "none in:likes"');
|
await fillIn('.search-query', 'none');
|
||||||
});
|
await click('.search-advanced-options .in-likes');
|
||||||
|
|
||||||
|
assert.ok(exists('.search-advanced-options .in-likes:checked'), 'has "I liked" populated');
|
||||||
|
assert.equal(find('.search-query').val(), "none in:likes", 'has updated search term to "none in:likes"');
|
||||||
});
|
});
|
||||||
|
|
||||||
QUnit.test("update in:private filter through advanced search ui", assert => {
|
QUnit.test("update in:private filter through advanced search ui", assert => {
|
||||||
|
2
vendor/assets/javascripts/run-qunit.js
vendored
2
vendor/assets/javascripts/run-qunit.js
vendored
@ -57,7 +57,7 @@ async function runAllTests() {
|
|||||||
// If it's a simple test result, write without newline
|
// If it's a simple test result, write without newline
|
||||||
if(message === "." || message === "F"){
|
if(message === "." || message === "F"){
|
||||||
process.stdout.write(message);
|
process.stdout.write(message);
|
||||||
} else if (message.startsWith("AUTOSPEC:")) {
|
} else if (message && message.startsWith("AUTOSPEC:")) {
|
||||||
fs.appendFileSync(QUNIT_RESULT, `${message.slice(10)}\n`);
|
fs.appendFileSync(QUNIT_RESULT, `${message.slice(10)}\n`);
|
||||||
} else {
|
} else {
|
||||||
console.log(message);
|
console.log(message);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user