This commit is contained in:
@@ -72,6 +72,13 @@ test("accepts only the supported public search sort values", () => {
|
||||
);
|
||||
});
|
||||
|
||||
test("accepts public status and newly-added filters", () => {
|
||||
const query = createSearchQuery({ status: "SOLD", newlyAdded: true });
|
||||
assert.equal(query.status, "SOLD");
|
||||
assert.equal(query.newlyAdded, true);
|
||||
assert.throws(() => createSearchQuery({ status: "UNKNOWN" }), /status must be/);
|
||||
});
|
||||
|
||||
test("normalizes whitespace and punctuation in free-text search terms", () => {
|
||||
assert.equal(
|
||||
normalizeSearchQuery(" Pikachu #199 / holo "),
|
||||
|
||||
Reference in New Issue
Block a user