<feed xmlns='http://www.w3.org/2005/Atom'>
<title>emacs-wttrin/tests/test-wttrin--fetch-url.el, branch main</title>
<subtitle>Emacs frontend for Igor Chubin's wttr.in weather service
</subtitle>
<id>https://git.cjennings.net/emacs-wttrin/atom?h=main</id>
<link rel='self' href='https://git.cjennings.net/emacs-wttrin/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/emacs-wttrin/'/>
<updated>2026-04-04T21:32:16+00:00</updated>
<entry>
<title>feat: specific error messages for fetch failures</title>
<updated>2026-04-04T21:32:16+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-04-04T21:32:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/emacs-wttrin/commit/?id=73c81a00a10766900318d86640249d1b54c6b351'/>
<id>urn:sha1:73c81a00a10766900318d86640249d1b54c6b351</id>
<content type='text'>
Add HTTP status code checking (wttrin--extract-http-status) and pass
error descriptions through the callback chain so users see "Location
not found (HTTP 404)" or "Network error — check your connection"
instead of the generic "Perhaps the location was misspelled?" for
every failure.

Also fix pre-existing bug where the condition-case error handler in
extract-response-body killed an unrelated buffer after unwind-protect
already cleaned up.

330 tests (was 307), all passing.
</content>
</entry>
<entry>
<title>doc: update copyright years to 2026 and add missing author field</title>
<updated>2026-04-04T17:51:32+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-04-04T17:51:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/emacs-wttrin/commit/?id=622ae39ad1e2544980cff73af8a5d5b2a64dacc8'/>
<id>urn:sha1:622ae39ad1e2544980cff73af8a5d5b2a64dacc8</id>
<content type='text'>
Update copyright headers across all 37 .el files to include 2026.
Add missing Author field to testutil-wttrin.el for consistency.
</content>
</entry>
<entry>
<title>refactor: tests: standardize naming, consolidate files, and expand testutil</title>
<updated>2026-02-18T01:14:14+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-02-18T01:14:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/emacs-wttrin/commit/?id=28b7e4cecadce207d532b8d42346c3823450a35f'/>
<id>urn:sha1:28b7e4cecadce207d532b8d42346c3823450a35f</id>
<content type='text'>
- Expand testutil-wttrin.el with shared fixtures and macros
  (testutil-wttrin-with-clean-weather-buffer,
  testutil-wttrin-mock-http-response, sample ANSI/weather constants)
- Consolidate cache tests: port unique tests from cleanup-cache-constants
  and cleanup-cache-refactored into cleanup-cache-if-needed, delete
  obsolete files
- Extract startup-delay tests into dedicated file
- Add setup/teardown and (require 'testutil-wttrin) to all test files
- Rename all 160 tests to follow
  test-&lt;module&gt;-&lt;category&gt;-&lt;scenario&gt;-&lt;expected-result&gt; convention
- Rename integration test file and add detailed docstrings
- Update Makefile glob to discover new integration test naming pattern

Co-Authored-By: Claude Opus 4.6 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>refactor: fetch: extract response parsing into separate testable functions</title>
<updated>2025-11-13T18:04:39+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-11-13T18:04:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/emacs-wttrin/commit/?id=0e71902e2a2dc16427f0b0274b4c968bcb05fa4f'/>
<id>urn:sha1:0e71902e2a2dc16427f0b0274b4c968bcb05fa4f</id>
<content type='text'>
Extracted wttrin--extract-response-body and wttrin--handle-fetch-callback
from wttrin--fetch-url to improve testability and separation of concerns.
Added comprehensive unit tests for both new functions.
</content>
</entry>
<entry>
<title>refactor: fetch: extract duplicate URL fetching logic into wttrin--fetch-url</title>
<updated>2025-11-08T16:26:17+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-11-08T16:26:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/emacs-wttrin/commit/?id=44d48bad4d317ce8fd9361314d349b1256e6c25b'/>
<id>urn:sha1:44d48bad4d317ce8fd9361314d349b1256e6c25b</id>
<content type='text'>
- Created wttrin--fetch-url helper to eliminate code duplication
- Refactored wttrin-fetch-raw-string to use helper (27 lines -&gt; 3 lines)
- Refactored wttrin--mode-line-fetch-weather to use helper (~30 lines -&gt; ~10 lines)
- Added comprehensive ERT test suite with 9 tests covering normal, boundary, and error cases
- All tests passing

This refactoring provides a single point of truth for async URL fetching,
making the code more maintainable and reducing duplication by ~40 lines.
</content>
</entry>
</feed>
