Yuan1z0825/nature-skills / skills/nature-academic-search
nature-academic-search
FlaggedSearch literature across sources, verify or manage citations, and build MeSH strategies or citation-impact audits. Use for 文献检索、引文核对、参考文献管理、严格他引 and evidence-backed citer profiles; not for translating a paper or drafting manuscript prose.
mcp-server/tests/test_scopus_empty_result.py
View on GitHub"""A Scopus empty result set must not become a fake paper."""
from __future__ import annotations
from unittest.mock import patch
def test_scopus_empty_result_set_yields_no_results():
from sources.scopus import ScopusSource
data = {
"search-results": {
"opensearch:totalResults": "0",
"entry": [{"@_fa": "true", "error": "Result set was empty"}],
}
}
with patch.object(ScopusSource, "_search_api", return_value=data), patch.object(
ScopusSource, "_run", side_effect=lambda operation, callback: callback()
):
result = ScopusSource().search("TITLE(xyzzy-no-such-paper)")
assert result["total"] == 0
assert result["results"] == []
def test_scopus_real_entries_are_kept():
from sources.scopus import _search_entries
data = {"search-results": {"entry": [{"dc:title": "A paper", "prism:doi": "10.1/x"}, {"error": "Result set was empty"}]}}
assert [e["dc:title"] for e in _search_entries(data)] == ["A paper"]
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| rea-analysis-optimizationmorluto/reaOptimize REA providers and shared analysis workflows for agent context, latency, CPU, and memory while preserving correctness and Evidence. Use for analysis bottlenecks and cache or query design; CI/test-suite optimization belongs to rea-ci-tests-audit. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| rea-ci-tests-auditmorluto/reaAudit REA CI and test suites for correctness, fixture drift, false passes, and measured performance; use for suite or workflow investigations and efficiency changes, rather than ordinary feature testing or a single test failure. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| rea-tool-designmorluto/reaAudit, investigate, design, or change REA investigation tools, CLI/MCP contracts, provider capabilities, and Evidence semantics. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-auditDietrichGebert/ponytailQuality audit of the whole repo: bugs, security, real load, missing tests, speed, and what to delete. Most important first. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |