Name the feed orders What I'm looking for, What fits me and Newest, drop Show hidden companies and show the judge's numbers of 10
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
b6e27fcb26
commit
463e53ac32
4 files changed
+102
-82
No files matched your search
+6
-4
@@ -579,10 +579,12 @@ kbd {
|
||||
font-size: .8rem; padding: .18rem .3rem;
|
||||
border: 1px solid var(--line);
|
||||
}
|
||||
/* The three order labels share one line: Agent match is the longest and
|
||||
would otherwise wrap in a 240px rail. Cells grow to the width, each by its
|
||||
own text. */
|
||||
#sort button { white-space: nowrap; }
|
||||
/* The three order labels share one row. What I'm looking for is longer than
|
||||
a 240px rail has room for on one line, so a cell may wrap its words; the
|
||||
cells split the width by their text, the short ones keeping theirs. */
|
||||
#sort button { min-width: 0; line-height: 1.2; }
|
||||
#sort button:nth-child(2), #sort button:nth-child(3) { flex-grow: 0; white-space: nowrap; }
|
||||
#sort button:first-child { flex-basis: 0; flex-grow: 1; }
|
||||
/* Square everything first; only the ends are ends. Every cell but the first
|
||||
eats its neighbour's border, so the joins are one rule wide rather than two. */
|
||||
.seg > * { border-radius: 0; }
|
||||
|
||||
+67
-75
@@ -10,10 +10,11 @@
|
||||
*
|
||||
* A row is newsdesk's `.row`: the score gutter and number (hidden under
|
||||
* Newest, since the score is not what put the row there, and the CV
|
||||
* match under CV match, a dash for a role not judged yet), the title,
|
||||
* match under What fits me, a dash for a role not judged yet), the title,
|
||||
* company · place · badges · age · tags, the summary or the description's
|
||||
* opening, and ▼ ● ▲ ★ from judge.js. A passed role and a hidden company's
|
||||
* are dimmed, never dropped, so a stray tap stays visible to be undone.
|
||||
* opening, and ▼ ● ▲ ★ from judge.js. A passed role is dimmed, never
|
||||
* dropped, so a stray tap stays visible to be undone. A hidden company's roles
|
||||
* are never in the feed.
|
||||
*
|
||||
* Opening a role pushes `/roles/{uid}`; closing goes back. Stepping with j/k
|
||||
* while it is open replaces that entry rather than stacking one per role, so
|
||||
@@ -32,12 +33,12 @@
|
||||
* Picking another reloads the feed and the counts under the reader, which
|
||||
* stays open and is fetched again for that agent's vote.
|
||||
*
|
||||
* Order is Agent match (`order=score`, the agent's final score moved by its
|
||||
* votes), Newest (`order=newest`) or CV match (`order=cv`, the roles the
|
||||
* agent's `judge` read against its CV first, by that total), the same three
|
||||
* whichever agent is viewed, and all carry the agent's votes and hidden
|
||||
* companies. CV match needs a CV: an agent without one is shown Agent
|
||||
* match, as an agentless page is shown Newest. Every order keeps to the
|
||||
* Order is What I'm looking for (`order=score`, the agent's want feed score
|
||||
* moved by its votes), Newest (`order=newest`) or What fits me (`order=cv`,
|
||||
* the roles the agent's `judge` read against its CV first, by that total),
|
||||
* the same three whichever agent is viewed, and all carry the agent's votes.
|
||||
* What fits me needs a CV: an agent without one is shown What I'm looking
|
||||
* for, as an agentless page is shown Newest. Every order keeps to the
|
||||
* roles the agent's fetch gate passes, which a note under Viewing as says;
|
||||
* Show gated (`gated=true`) adds the ones it rejects, with the reason.
|
||||
*
|
||||
@@ -128,10 +129,11 @@
|
||||
};
|
||||
const TRACKS = { "": "Both", ic: "Individual", people: "People" };
|
||||
|
||||
// What the list is in the order of. Agent match is the viewing agent's
|
||||
// score, moved by its votes; Newest is first seen; CV match is
|
||||
// the agent's `judge` total, the roles not judged after by score.
|
||||
const SORTS = { score: "Agent match", cv: "CV match", time: "Newest" };
|
||||
// What the list is in the order of. What I'm looking for is the viewing
|
||||
// agent's want feed score, moved by its votes; Newest is first seen; What
|
||||
// fits me is the agent's `judge` total, the roles not judged after by CV
|
||||
// closeness.
|
||||
const SORTS = { score: "What I\u2019m looking for", cv: "What fits me", time: "Newest" };
|
||||
// The route's `order` for each.
|
||||
const ORDERS = { score: "score", time: "newest", cv: "cv" };
|
||||
// How many days ahead a deadline earns a badge: today to today + 4, the
|
||||
@@ -162,7 +164,7 @@
|
||||
return {
|
||||
sort: "score", agent: null, period: "all", tags: new Set(), showRead: true,
|
||||
company: "", place: "", function: "", remote: "", judged: "", pay: "",
|
||||
showMuted: false, gated: false, companyKeys: [], places: [],
|
||||
gated: false, companyKeys: [], places: [],
|
||||
levelFrom: "", levelTo: "", track: "", seniorityUnknown: true, payUnknown: false,
|
||||
closing: false,
|
||||
};
|
||||
@@ -174,7 +176,7 @@
|
||||
counted. */
|
||||
function filtersOn(f = state.filter, { more = false } = {}) {
|
||||
const folded = [f.company.trim(), f.place.trim(), f.function, f.remote, f.pay, f.judged,
|
||||
f.showMuted, f.closing, f.agent !== null && f.gated].filter(Boolean).length
|
||||
f.closing, f.agent !== null && f.gated].filter(Boolean).length
|
||||
+ f.companyKeys.length + f.places.length
|
||||
+ [f.levelFrom, f.levelTo, f.track].filter(Boolean).length;
|
||||
if (more) return folded;
|
||||
@@ -225,13 +227,14 @@
|
||||
/** The viewing agent, once the agents are in. */
|
||||
const viewed = () => state.agents.find((a) => a.id === state.filter.agent) || null;
|
||||
|
||||
/** Whether CV match has a CV to go by: the viewed agent has one, or
|
||||
/** Whether What fits me has a CV to go by: the viewed agent has one, or
|
||||
the agents are not in yet, when the address is taken at its word. */
|
||||
const hasCv = () => !state.agentsLoaded || Boolean(viewed()?.cv_text?.trim());
|
||||
|
||||
/** The order the list is in. Agent match needs an agent to score by: with
|
||||
none enabled the server answers newest first, and so does this. Best
|
||||
CV match needs that agent's CV too, and without one is Agent match. */
|
||||
/** The order the list is in. What I'm looking for needs an agent to score
|
||||
by: with none enabled the server answers newest first, and so does this.
|
||||
What fits me needs that agent's CV too, and without one is What I'm
|
||||
looking for. */
|
||||
function sortShown() {
|
||||
const { sort, agent } = state.filter;
|
||||
if (sort === "time" || agent === null) return "time";
|
||||
@@ -249,7 +252,6 @@
|
||||
for (const key of ["function", "remote", "judged", "pay"]) if (f[key]) p.set(key, f[key]);
|
||||
const days = PERIODS[f.period].days;
|
||||
if (days) p.set("days", String(days));
|
||||
if (f.showMuted) p.set("show_muted", "true");
|
||||
if (!f.showRead) p.set("include_read", "false");
|
||||
f.tags.forEach((t) => p.append("tags", t));
|
||||
f.companyKeys.forEach((key) => p.append("company_keys", key));
|
||||
@@ -286,7 +288,6 @@
|
||||
f[key] = q.get(key) || "";
|
||||
}
|
||||
f.period = PERIOD_OF_DAYS[q.get("days")] || "all";
|
||||
f.showMuted = q.get("show_muted") === "true";
|
||||
f.showRead = q.get("include_read") !== "false";
|
||||
f.gated = q.get("gated") === "true" || q.get("gated") === "1";
|
||||
f.tags = new Set(q.getAll("tags"));
|
||||
@@ -387,7 +388,6 @@
|
||||
written into the entry landed on, so the entry says what is shown. */
|
||||
function restore() {
|
||||
const before = addressFor(pathFor(null));
|
||||
const muted = state.filter.showMuted;
|
||||
readUrl(location.search, { view: false });
|
||||
$("#search").value = state.q;
|
||||
writeUrl();
|
||||
@@ -397,7 +397,6 @@
|
||||
labelPlaces();
|
||||
if (addressFor(pathFor(null)) === before) return;
|
||||
reload();
|
||||
if (state.filter.showMuted !== muted) loadFilters().catch(() => {});
|
||||
renderRail();
|
||||
renderActive();
|
||||
}
|
||||
@@ -514,12 +513,11 @@
|
||||
if (state.readingUid) refreshReader(state.readingUid);
|
||||
}
|
||||
|
||||
// The tag counts. Asked with `show_muted` and the agent only, the filters
|
||||
// the route takes, so picking a tag does not renumber the others.
|
||||
// The tag counts. Asked with the agent only, the filter the route takes, so
|
||||
// picking a tag does not renumber the others.
|
||||
let filtersRequest = 0;
|
||||
async function loadFilters() {
|
||||
const params = new URLSearchParams();
|
||||
if (state.filter.showMuted) params.set("show_muted", "true");
|
||||
if (state.filter.agent !== null) params.set("agent", String(state.filter.agent));
|
||||
const request = ++filtersRequest;
|
||||
const data = await api(`/api/filters?${params}`);
|
||||
@@ -547,7 +545,7 @@
|
||||
it: pushed, so back takes the filter off and brings the role back, or
|
||||
replacing the entry for text being typed (`replace`). A filter that
|
||||
changes nothing only closes the reader. */
|
||||
function setFilter(patch = {}, { counts = false, replace = false } = {}) {
|
||||
function setFilter(patch = {}, { replace = false } = {}) {
|
||||
Object.assign(state.filter, patch);
|
||||
if (state.readingUid && addressFor(pathFor(null)) === pathFor(null) + location.search) {
|
||||
closeReader();
|
||||
@@ -556,7 +554,6 @@
|
||||
route();
|
||||
}
|
||||
reload();
|
||||
if (counts) loadFilters().catch(() => {});
|
||||
renderRail();
|
||||
renderActive();
|
||||
}
|
||||
@@ -568,7 +565,7 @@
|
||||
// Text half typed into a chip field goes too, and with it its list.
|
||||
companyChips?.clear();
|
||||
placeChips?.clear();
|
||||
setFilter({}, { counts: true });
|
||||
setFilter();
|
||||
}
|
||||
|
||||
/* The other order over the same filter: the entry is replaced, since an
|
||||
@@ -593,11 +590,9 @@
|
||||
|
||||
/** Where a company's name links: the list on screen, every filter and the
|
||||
search kept, with this company as its one company filter, in place of
|
||||
any company chips and of `?company=`. A company this agent hid turns
|
||||
on Show hidden companies, or its own name would lead to an empty list. */
|
||||
any company chips and of `?company=`. */
|
||||
function companyHref(key) {
|
||||
const f = Object.assign({}, state.filter, { companyKeys: [key], company: "" });
|
||||
if (companies.get(key)?.affinity === -1) f.showMuted = true;
|
||||
return addressFor(pathFor(null), f);
|
||||
}
|
||||
|
||||
@@ -627,10 +622,9 @@
|
||||
const link = e.currentTarget;
|
||||
link.href = companyHref(link.dataset.company);
|
||||
companyNames.set(link.dataset.company, link.textContent.trim());
|
||||
const counts = state.filter.showMuted;
|
||||
readUrl(new URL(link.href).search, { view: false });
|
||||
$("#search").value = state.q;
|
||||
setFilter({}, { counts: counts !== state.filter.showMuted });
|
||||
setFilter();
|
||||
}
|
||||
|
||||
/* The strip's way back to every company: back, when the entry under this
|
||||
@@ -669,8 +663,8 @@
|
||||
|
||||
renderAgent();
|
||||
|
||||
// The order, the same three whatever is viewed. Agent match needs an
|
||||
// agent to score by, and CV match that agent's CV, so without one
|
||||
// The order, the same three whatever is viewed. What I'm looking for needs
|
||||
// an agent to score by, and What fits me that agent's CV, so without one
|
||||
// each is greyed and says why.
|
||||
const none = state.agentsLoaded && !state.agents.length;
|
||||
const why = {
|
||||
@@ -714,7 +708,6 @@
|
||||
setValue("f-remote", f.remote);
|
||||
setValue("f-pay", f.pay);
|
||||
setValue("f-judged", f.judged);
|
||||
setValue("f-show-muted", f.showMuted);
|
||||
setValue("f-closing", f.closing);
|
||||
setValue("f-gated", f.gated);
|
||||
renderFacets();
|
||||
@@ -852,7 +845,7 @@
|
||||
gate.hidden = state.filter.agent === null;
|
||||
gate.textContent = state.filter.gated
|
||||
? "Filtered by this agent's fetch gate, and Show gated adds the roles it rejects."
|
||||
: "Already filtered by this agent's fetch gate: region, places and role.";
|
||||
: "Already filtered by this agent's fetch gate: world, location and role exclusion. Hidden companies are never shown.";
|
||||
if (agents.length) {
|
||||
// Rebuilt only when the agents changed, since the rail is drawn again on
|
||||
// every filter and a rebuild shuts a select that is open.
|
||||
@@ -950,7 +943,6 @@
|
||||
async function applySaved(id) {
|
||||
const saved = state.saved.find((x) => x.id === id);
|
||||
if (!saved) return;
|
||||
const muted = state.filter.showMuted;
|
||||
const query = new URLSearchParams(saved.query);
|
||||
readUrl(`?${saved.query}`, { view: false });
|
||||
const sort = query.get("sort");
|
||||
@@ -961,7 +953,7 @@
|
||||
await labelPlaces({ write: false });
|
||||
if (filtersOn(state.filter, { more: true })) $("#f-more").open = true;
|
||||
if (overlayRail() && state.railOpen) toggleRail();
|
||||
setFilter({}, { counts: muted !== state.filter.showMuted });
|
||||
setFilter();
|
||||
}
|
||||
|
||||
async function deleteSaved(id) {
|
||||
@@ -1236,7 +1228,7 @@
|
||||
}
|
||||
|
||||
/* The gutter's number, of 100, and what it says: the agent's score, or
|
||||
under CV match the CV match. A role `judge` has not read yet has an
|
||||
under What fits me the CV match. A role `judge` has not read yet has an
|
||||
empty bar and, faint, how close it is to the CV (`cv_fit`), which is
|
||||
what orders it there, else a dash. */
|
||||
function gutterOf(role) {
|
||||
@@ -1300,12 +1292,10 @@
|
||||
el.querySelector(".company")?.addEventListener("click", companyClick);
|
||||
}
|
||||
|
||||
/* A passed role and a hidden company's are dimmed, never dropped: the pass
|
||||
has to stay visible to be undone. */
|
||||
/* A passed role is dimmed, never dropped: the pass has to stay visible to be
|
||||
undone. */
|
||||
function paintRow(el, role) {
|
||||
const company = companies.get(role.company_key);
|
||||
el.dataset.read = String(Boolean(role.read_at));
|
||||
el.classList.toggle("muted", Boolean(company && company.affinity === -1));
|
||||
el.classList.toggle("passed", role.vote === -1);
|
||||
el.classList.toggle("gated", Boolean(role.gated_reason));
|
||||
}
|
||||
@@ -1432,38 +1422,41 @@
|
||||
}
|
||||
|
||||
/* Which parts of the viewing agent's fetch gate apply to a company's
|
||||
roles: All countries lifts the place part (the Where lines), All roles
|
||||
the role part (fetch terms, titles to leave out); the region always
|
||||
holds. A favourite only ranks higher, so it is not named here. Nothing
|
||||
with no agent, when no fetch gate applies. */
|
||||
roles: All locations lifts the location gate, All roles the role
|
||||
exclusion and the fetch terms; the world gate always holds. A favourite
|
||||
only ranks higher, so it is not named here. A hidden company has no
|
||||
roles in the feed at all. Nothing with no agent, when no fetch gate
|
||||
applies. */
|
||||
function gateNote(company) {
|
||||
if (state.filter.agent === null) return "";
|
||||
const countries = Boolean(company?.all_countries);
|
||||
if (company?.affinity === -1) return "Hidden for this agent: its roles are never shown.";
|
||||
const locations = Boolean(company?.all_countries);
|
||||
const roles = Boolean(company?.all_roles);
|
||||
if (countries && roles) {
|
||||
return "All countries and All roles: every role in the agent's region, "
|
||||
+ "not filtered by place or by role.";
|
||||
if (locations && roles) {
|
||||
return "All locations and All roles: every role in the agent's world, "
|
||||
+ "not filtered by location, role exclusion or fetch terms.";
|
||||
}
|
||||
if (countries) {
|
||||
return "All countries: every role in the agent's region, not filtered by place. "
|
||||
+ "The agent's fetch terms and titles to leave out still apply.";
|
||||
if (locations) {
|
||||
return "All locations: every role in the agent's world, not filtered by location. "
|
||||
+ "The agent's role exclusion still applies.";
|
||||
}
|
||||
if (roles) {
|
||||
return "All roles: not filtered by role, no fetch terms and no titles left out. "
|
||||
+ "The agent's places still apply.";
|
||||
return "All roles: no titles left out and no fetch terms. "
|
||||
+ "The agent's locations still apply.";
|
||||
}
|
||||
return "The roles this agent's fetch gate passes: its region, places and role. "
|
||||
+ "All countries lifts the places for this company, All roles the role.";
|
||||
return "The roles this agent's fetch gate passes: its world, locations and role exclusion. "
|
||||
+ "All locations lifts the locations for this company, All roles the role exclusion.";
|
||||
}
|
||||
|
||||
/* A company seen only through a search has no row until its first change
|
||||
creates one, so the list is reloaded then. A change dims or undims its
|
||||
rows at once; where they rank waits on the `score` it queued, whose id
|
||||
the affinity route answers with (`updated.score_job`), and the feed
|
||||
reloads when that has finished. */
|
||||
creates one, so the list is reloaded then. Hiding takes the company's
|
||||
rows out at once, since a hidden company is never in the feed; where the
|
||||
others rank waits on the `score` it queued, whose id the affinity route
|
||||
answers with (`updated.score_job`), and the feed reloads when that has
|
||||
finished. */
|
||||
async function affinityChanged(key, company, updated) {
|
||||
if (!company) await loadCompanies(state.filter.agent).catch(() => {});
|
||||
renderFeed();
|
||||
if (updated?.affinity === -1) reload(); else renderFeed();
|
||||
const status = () => $("#company-strip .strip-status");
|
||||
if (status()) status().textContent = "Scoring again; the list reloads when that is done.";
|
||||
await scored(updated?.score_job);
|
||||
@@ -1644,7 +1637,7 @@
|
||||
const MUST_MARKS = { met: ["✓", "met"], broken: ["✗", "broken"], unclear: ["?", "unclear"] };
|
||||
|
||||
/* The agent's `judge` reading against its CV: the total and its three
|
||||
numbers, career as the server counted it (capped at 39 when a must-have
|
||||
numbers, each of 10, career as the server counted it (capped at 4 when a must-have
|
||||
is broken, with what the model said), the must-haves with a verdict
|
||||
each, then the strengths and gaps it named. A box as the summary is,
|
||||
since it is the same kind of thing: a model's reading, not the posting. */
|
||||
@@ -1656,7 +1649,8 @@
|
||||
: `<p class="muted small">${none}</p>`);
|
||||
const counted = j.career_capped ?? j.career;
|
||||
const career = counted < j.career
|
||||
? `career ${counted} (capped: breaks a must-have; model said ${j.career})` : `career ${j.career}`;
|
||||
? `career ${counted}/10 (capped: breaks a must-have; model said ${j.career}/10)`
|
||||
: `career ${j.career}/10`;
|
||||
const musts = Array.isArray(j.musts) && j.musts.length
|
||||
? `<ul class="cv-musts">${j.musts.map((m) => {
|
||||
const [mark, word] = MUST_MARKS[m.verdict] || MUST_MARKS.unclear;
|
||||
@@ -1666,7 +1660,7 @@
|
||||
return `<section class="reader-summary reader-cv">
|
||||
<h2 class="reader-label">CV match</h2>
|
||||
<p class="cv-total"><b>${Math.round(j.cv_score)}</b> of 100
|
||||
<span>skills ${j.skills} · experience ${j.experience} · ${career}</span></p>
|
||||
<span>skills ${j.skills}/10 · experience ${j.experience}/10 · ${career}</span></p>
|
||||
${musts}
|
||||
<div class="cv-lists">
|
||||
<div><h3 class="reader-label">Strengths</h3>${list(j.strengths, "None named.")}</div>
|
||||
@@ -1812,15 +1806,15 @@
|
||||
/* The company's ⊘ ▲ ★, the one place a company is judged outside the
|
||||
Companies page, and its two fetch overrides beside them. A company seen
|
||||
only through a search has no row until its first change creates one, so
|
||||
the list is reloaded then, and the overrides, which need a row, wait for it. A
|
||||
change dims or undims its rows in the feed. */
|
||||
the list is reloaded then, and the overrides, which need a row, wait for it.
|
||||
Hiding reloads the feed, which no longer holds the company's roles. */
|
||||
function renderAffinity(slot, r) {
|
||||
const company = companies.get(r.company_key);
|
||||
if (!r.company_key) { slot.replaceChildren(); return; }
|
||||
slot.replaceChildren(affinityControl(r.company_key, company ? company.affinity : 0, async () => {
|
||||
slot.replaceChildren(affinityControl(r.company_key, company ? company.affinity : 0, async (updated) => {
|
||||
if (!company) await loadCompanies(state.filter.agent).catch(() => {});
|
||||
renderAffinity(slot, r);
|
||||
renderFeed();
|
||||
if (updated?.affinity === -1) reload(); else renderFeed();
|
||||
}, state.filter.agent));
|
||||
if (company) {
|
||||
slot.append(" ", overridesControl(r.company_key, company,
|
||||
@@ -2109,8 +2103,6 @@
|
||||
});
|
||||
$("#f-seniority-unknown").addEventListener("change",
|
||||
(e) => setFilter({ seniorityUnknown: e.target.checked }));
|
||||
$("#f-show-muted").addEventListener("change",
|
||||
(e) => setFilter({ showMuted: e.target.checked }, { counts: true }));
|
||||
$("#f-gated").addEventListener("change", (e) => setFilter({ gated: e.target.checked }));
|
||||
$("#f-closing").addEventListener("change", (e) => setFilter({ closing: e.target.checked }));
|
||||
|
||||
@@ -2187,7 +2179,7 @@
|
||||
// known, and either way bring the reader's affinity control and judge
|
||||
// buttons up to date, since `companies` was still empty when it first
|
||||
// painted.
|
||||
// CV match asked of an agent with no CV is Agent match.
|
||||
// What fits me asked of an agent with no CV is What I'm looking for.
|
||||
if (state.filter.agent !== before || sortShown() !== sortBefore) reload();
|
||||
else renderFeed();
|
||||
if (state.readingUid) {
|
||||
|
||||
@@ -149,9 +149,6 @@
|
||||
<label class="check">
|
||||
<input type="checkbox" id="f-closing"> Closing soon
|
||||
</label>
|
||||
<label class="check">
|
||||
<input type="checkbox" id="f-show-muted"> Show hidden companies
|
||||
</label>
|
||||
{# The roles the agent's fetch gate rejects, each with the reason,
|
||||
in any order; offered only with an agent. #}
|
||||
<label class="check" id="show-gated" hidden
|
||||
|
||||
@@ -81,3 +81,32 @@ def test_a_saved_filter_round_trips_the_query_roles_js_writes(
|
||||
# the page treats as done.
|
||||
assert client.delete(f"/api/filters/{made.json()['id']}").status_code == 404
|
||||
assert client.get(f"/api/agents/{agent.id}/filters").json() == []
|
||||
|
||||
|
||||
def test_the_feed_orders_carry_the_adrs_names() -> None:
|
||||
script = (STATIC / "roles.js").read_text()
|
||||
assert "What I\\u2019m looking for" in script and '"What fits me"' in script
|
||||
assert 'time: "Newest"' in script
|
||||
assert "Agent match" not in script
|
||||
|
||||
|
||||
def test_the_rail_has_no_show_hidden_companies_and_the_feed_never_asks_for_them(
|
||||
client: TestClient) -> None:
|
||||
page = client.get("/").text
|
||||
assert "f-show-muted" not in page and "Show hidden companies" not in page
|
||||
script = (STATIC / "roles.js").read_text()
|
||||
assert "show_muted" not in script and "showMuted" not in script
|
||||
|
||||
|
||||
def test_the_reader_shows_the_judges_numbers_of_ten() -> None:
|
||||
script = (STATIC / "roles.js").read_text()
|
||||
assert "skills ${j.skills}/10" in script and "experience ${j.experience}/10" in script
|
||||
assert "career ${j.career}/10" in script
|
||||
assert "of 100" in script # the CV match itself stays on 0 to 100
|
||||
|
||||
|
||||
def test_every_page_says_all_locations() -> None:
|
||||
for path in STATIC.glob("*.js"):
|
||||
assert "All countries" not in path.read_text(), path.name
|
||||
for path in (STATIC.parent / "templates").rglob("*.html"):
|
||||
assert "All countries" not in path.read_text(), path.name
|
||||
Reference in new issue
Block a user