generated from coulomb/repo-seed
Milestone 5 polish
This commit is contained in:
@@ -161,6 +161,8 @@ def test_search_filters_by_status_language_and_framework(tmp_path):
|
||||
status="indexed",
|
||||
language="Python",
|
||||
framework="FastAPI",
|
||||
ability="Repository Usefulness",
|
||||
capability="Repository Structure",
|
||||
)
|
||||
wrong_language_results = service.search(
|
||||
"repository",
|
||||
@@ -168,10 +170,18 @@ def test_search_filters_by_status_language_and_framework(tmp_path):
|
||||
language="TypeScript",
|
||||
framework="FastAPI",
|
||||
)
|
||||
wrong_capability_results = service.search(
|
||||
"repository",
|
||||
status="indexed",
|
||||
language="Python",
|
||||
framework="FastAPI",
|
||||
capability="Email Routing",
|
||||
)
|
||||
|
||||
assert results
|
||||
assert {result.repository_name for result in results} == {"Filterable"}
|
||||
assert wrong_language_results == []
|
||||
assert wrong_capability_results == []
|
||||
|
||||
|
||||
def test_register_repository_imports_metadata_when_name_is_omitted(tmp_path):
|
||||
|
||||
@@ -215,7 +215,12 @@ def test_api_analysis_run_loop(tmp_path):
|
||||
|
||||
filtered_search_response = client.get(
|
||||
"/search",
|
||||
params={"q": "frontend", "status": "indexed"},
|
||||
params={
|
||||
"q": "frontend",
|
||||
"status": "indexed",
|
||||
"ability": "Frontend",
|
||||
"capability": "Frontend Stack",
|
||||
},
|
||||
)
|
||||
assert filtered_search_response.status_code == 200
|
||||
assert filtered_search_response.json()
|
||||
@@ -315,10 +320,17 @@ def test_ui_register_analyze_and_approve_loop(tmp_path):
|
||||
assert search_response.status_code == 200
|
||||
assert "UI Repo" in search_response.text
|
||||
assert "Field" in search_response.text
|
||||
assert "#capability-" in search_response.text or "#ability-" in search_response.text
|
||||
|
||||
filtered_search_response = client.get(
|
||||
"/ui/search",
|
||||
params={"q": "repository", "status": "indexed", "language": "Python"},
|
||||
params={
|
||||
"q": "repository",
|
||||
"status": "indexed",
|
||||
"language": "Python",
|
||||
"ability": "Repository Usefulness",
|
||||
"capability": "Repository",
|
||||
},
|
||||
)
|
||||
assert filtered_search_response.status_code == 200
|
||||
assert "UI Repo" in filtered_search_response.text
|
||||
|
||||
Reference in New Issue
Block a user