{
    "archive_path": "archive/1754185356.832198",
    "base_url": "lobste.rs/s/gijhis/unit_testing_principles",
    "basename": "unit_testing_principles",
    "bookmarked_date": "2025-08-03 01:42",
    "canonical": {
        "archive_org_path": "https://web.archive.org/web/lobste.rs/s/gijhis/unit_testing_principles",
        "dom_path": "output.html",
        "favicon_path": "favicon.ico",
        "git_path": "git/",
        "google_favicon_path": "https://www.google.com/s2/favicons?domain=lobste.rs",
        "headers_path": "headers.json",
        "htmltotext_path": "htmltotext.txt",
        "index_path": "index.html",
        "media_path": "media/",
        "mercury_path": "mercury/content.html",
        "pdf_path": "output.pdf",
        "readability_path": "readability/content.html",
        "screenshot_path": "screenshot.png",
        "singlefile_path": "singlefile.html",
        "warc_path": "warc/",
        "wget_path": null
    },
    "domain": "lobste.rs",
    "downloaded_at": "2025-08-03T01:42:41.356096+00:00",
    "downloaded_datestr": "2025-08-03 01:42",
    "extension": "",
    "hash": "V9EN9MFBVQHVKVXMYZER",
    "history": {
        "archive_org": [
            {
                "cmd": [
                    "/usr/bin/curl",
                    "--silent",
                    "--location",
                    "--compressed",
                    "--proxy",
                    "socks5://tor-socks-proxy:9150",
                    "--head",
                    "--max-time",
                    "60",
                    "--user-agent",
                    "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 ArchiveBox/{VERSION} (+https://github.com/ArchiveBox/ArchiveBox/)",
                    "https://web.archive.org/save/https://lobste.rs/s/gijhis/unit_testing_principles"
                ],
                "cmd_version": "8.10.1",
                "end_ts": "2025-08-03T01:44:12.268003+00:00",
                "index_texts": null,
                "output": "TimeoutExpired: Command '['/usr/bin/curl', '--silent', '--location', '--compressed', '--proxy', 'socks5://tor-socks-proxy:9150', '--head', '--max-time', '60', '--user-agent', 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 ArchiveBox/{VERSION} (+https://github.com/ArchiveBox/ArchiveBox/)', 'https://web.archive.org/save/https://lobste.rs/s/gijhis/unit_testing_principles']' timed out after 60 seconds",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:43:12.197581+00:00",
                "status": "failed"
            }
        ],
        "dom": [
            {
                "cmd": [
                    "/usr/bin/chromium-browser",
                    "--proxy-server=socks5://tor-socks-proxy:9150",
                    "--disable-features=DarkMode",
                    "--run-all-compositor-stages-before-draw",
                    "--hide-scrollbars",
                    "--autoplay-policy=no-user-gesture-required",
                    "--no-first-run",
                    "--use-fake-ui-for-media-stream",
                    "--use-fake-device-for-media-stream",
                    "--simulate-outdated-no-au='Tue, 31 Dec 2099 23:59:59 GMT'",
                    "--headless=new",
                    "--no-sandbox",
                    "--no-zygote",
                    "--disable-dev-shm-usage",
                    "--disable-software-rasterizer",
                    "--disable-sync",
                    "--window-size=1440,2000",
                    "--user-agent=Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 ArchiveBox/{VERSION} (+https://github.com/ArchiveBox/ArchiveBox/)",
                    "--user-data-dir=/data/personas/Default/chrome_profile",
                    "--profile-directory=Default",
                    "--dump-dom",
                    "https://lobste.rs/s/gijhis/unit_testing_principles"
                ],
                "cmd_version": "131.0.6778",
                "end_ts": "2025-08-03T01:42:50.555226+00:00",
                "index_texts": null,
                "output": "output.html",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:42:45.486176+00:00",
                "status": "succeeded"
            }
        ],
        "favicon": [
            {
                "cmd": [
                    "/usr/bin/curl",
                    "--silent",
                    "--location",
                    "--compressed",
                    "--proxy",
                    "socks5://tor-socks-proxy:9150",
                    "--max-time",
                    "60",
                    "--output",
                    "favicon.ico",
                    "--user-agent",
                    "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 ArchiveBox/{VERSION} (+https://github.com/ArchiveBox/ArchiveBox/)",
                    "https://www.google.com/s2/favicons?domain=lobste.rs"
                ],
                "cmd_version": "8.10.1",
                "end_ts": "2025-08-03T01:42:44.549679+00:00",
                "index_texts": null,
                "output": "favicon.ico",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:42:41.560274+00:00",
                "status": "succeeded"
            }
        ],
        "git": [],
        "headers": [
            {
                "cmd": [
                    "/usr/bin/curl",
                    "--silent",
                    "--location",
                    "--compressed",
                    "--proxy",
                    "socks5://tor-socks-proxy:9150",
                    "--head",
                    "--max-time",
                    "60",
                    "--user-agent",
                    "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 ArchiveBox/{VERSION} (+https://github.com/ArchiveBox/ArchiveBox/)",
                    "https://lobste.rs/s/gijhis/unit_testing_principles"
                ],
                "cmd_version": "8.10.1",
                "end_ts": "2025-08-03T01:42:45.058331+00:00",
                "index_texts": null,
                "output": "headers.json",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:42:44.589773+00:00",
                "status": "succeeded"
            }
        ],
        "htmltotext": [
            {
                "cmd": [
                    "(internal) archivebox.extractors.htmltotext",
                    "./{singlefile,dom}.html"
                ],
                "cmd_version": "0.8.5rc51",
                "end_ts": "2025-08-03T01:43:04.337309+00:00",
                "index_texts": [
                    "(/touch-icon-144.png) (/touch-icon.png) (/touch-icon.png) (/touch-icon-144.png) (/touch-icon-144.png) (/opensearch.xml) (Lobsters) (/favicon.ico) (https://lobste.rs/s/gijhis/unit_testing_principles) Unit Testing Principles | Lobsters (/assets/application-2f99e16b.css) (/assets/system-system-bf6d5bb3.css) (/assets/tom-select-9d6bcb6b.css) (/assets/TomSelect_remove_button-4d5c34b9.css)  (/) (Lobsters (Current traffic: 1%))  (/active) Active (/recent) Recent (/comments) Comments (/search) Search (/login) Login   (/login) Login   (/login) 13  (https://olano.dev/blog/unit-testing-principles/) Unit Testing Principles  (/t/practices) (Development and team practices) practices (/t/testing) (Software testing) testing  (/domains/olano.dev) olano.dev authored by (/~facundoolano) (facundoolano avatar)  (/~facundoolano) facundoolano (2025-08-01 16:51:33 -0500) 27 hours ago |  caches (https://web.archive.org/web/3/https%3A%2F%2Folano.dev%2Fblog%2Funit-testing-principles%2F) Archive.org (https://archive.today/https%3A%2F%2Folano.dev%2Fblog%2Funit-testing-principles%2F) Archive.today (https://ghostarchive.org/search?term=https%3A%2F%2Folano.dev%2Fblog%2Funit-testing-principles%2F) Ghostarchive   | (/s/gijhis/unit_testing_principles#comments_story_01k1kswvpafqv90vcydfh1acpk) 2\n              comments         (Vpfm-yN3ny25WBBfAXWoqycDPdiP3mUgrqCLOXTQCV7qOYfKW9tiHnllpjMazcrgensqQC-OXmDzm-aScT4gzQ) (gijhis) (post) (You must be logged in to leave a comment.)  (Post) Preview          (/login) 10   (/~matklad) (matklad avatar)  (/~matklad) matklad edited (/c/prrpxf) (2025-08-02 03:14:11 -0500) 17 hours ago      This is surprisingly reasonable despite using unit/integration dichotomy! Though, I continue to maintain that the most important insight about testing is that there are two independent axes here: how much IO is done by test (none > some FS access > some IPC > some HTTP to a different machine) which fraction of your codebase is exercised by the test (single function without dependencies > the entire thing)  (https://testing.googleblog.com/2010/12/test-sizes.html?m=1) https://testing.googleblog.com/2010/12/test-sizes.html?m=1  There\u2019s also third axes, whether we are testing a single unit of behavior, or a more complicated composite flow, but it is of the least consequences for writing tests. EDIT: worth pointing out how the article (and I presume the book) avoids the usual confusion: it re-defines the meaning of unit! It uses neither the original meaning (unit is the test itself , (https://web.archive.org/web/20150315073817/http://www.xprogramming.com/testfram.htm#:~:text=unit%20of%20testing) unit of testing , as a encoding of a defined part of a manual testing process in a repl), nor the acquired meaning (unit as a (https://en.wikipedia.org/wiki/Unit_testing) component or module ), and instead conveniently defines it as \u201cunit of behavior\u201d. There\u2019s some deep truth in here about naming things!      (/login)    (/~facundoolano) (facundoolano avatar)  (/~facundoolano) facundoolano (/c/stp6gm) (2025-08-02 19:15:13 -0500) 1 hour ago      That definition of unit is one of my favorite take-aways from the book. The (https://www.youtube.com/watch?v=6sNmJtoKDCo) Clarity talk mentioned at the beginning does a great job of showing how to use it when testing a feature.              (/about) About (/tags) Tags (/filters) Filter (/moderations) Moderation Log       "
                ],
                "output": "htmltotext.txt",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:43:04.312441+00:00",
                "status": "succeeded"
            }
        ],
        "media": [
            {
                "cmd": [
                    "/usr/local/bin/yt-dlp",
                    "--restrict-filenames",
                    "--trim-filenames",
                    "128",
                    "--write-description",
                    "--write-info-json",
                    "--write-annotations",
                    "--write-thumbnail",
                    "--no-call-home",
                    "--write-sub",
                    "--write-auto-subs",
                    "--convert-subs=srt",
                    "--yes-playlist",
                    "--continue",
                    "--no-abort-on-error",
                    "--ignore-errors",
                    "--geo-bypass",
                    "--add-metadata",
                    "--format=(bv*+ba/b)[filesize<=750m][filesize_approx<=?750m]/(bv*+ba/b)",
                    "--skip-download",
                    "--cache-dir=/data/yt-dlp-cache/",
                    "--cookies=/data/yt-dlp-cache/cookies.txt",
                    "--proxy=socks5://tor-socks-proxy:9150",
                    "--no-playlist",
                    "https://lobste.rs/s/gijhis/unit_testing_principles"
                ],
                "cmd_version": "2024.10.7",
                "end_ts": "2025-08-03T01:43:12.148019+00:00",
                "index_texts": [],
                "output": "media/",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:43:04.585721+00:00",
                "status": "succeeded"
            }
        ],
        "mercury": [
            {
                "cmd": [
                    "/home/archivebox/.npm/bin/postlight-parser",
                    "https://lobste.rs/s/gijhis/unit_testing_principles"
                ],
                "cmd_version": "2.2.3",
                "end_ts": "2025-08-03T01:43:04.270166+00:00",
                "index_texts": null,
                "output": "mercury/",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:42:56.259449+00:00",
                "status": "succeeded"
            }
        ],
        "pdf": [],
        "readability": [
            {
                "cmd": [
                    "/home/archivebox/.npm/bin/readability-extractor",
                    "/tmp/tmp26y24uil",
                    "https://lobste.rs/s/gijhis/unit_testing_principles"
                ],
                "cmd_version": "0.0.11",
                "end_ts": "2025-08-03T01:42:56.096504+00:00",
                "index_texts": [
                    "This is surprisingly reasonable despite using unit/integration dichotomy! Though, I continue to maintain that the most important insight about testing is that there are two independent axes here:\n\nhow much IO is done by test (none > some FS access > some IPC > some HTTP to a different machine)\nwhich fraction of your codebase is exercised by the test (single function without dependencies > the entire thing)\n\nhttps://testing.googleblog.com/2010/12/test-sizes.html?m=1\nThere\u2019s also third axes, whether we are testing a single unit of behavior, or a more complicated composite flow, but it is of the least consequences for writing tests.\nEDIT: worth pointing out how the article (and I presume the book) avoids the usual confusion: it re-defines the meaning of unit! It uses neither the original meaning (unit is the test itself, unit of testing, as a encoding of a defined part of a manual testing process in a repl), nor the acquired meaning (unit as a component or module), and instead conveniently defines it as \u201cunit of behavior\u201d. There\u2019s some deep truth in here about naming things!"
                ],
                "output": "readability/",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:42:51.323246+00:00",
                "status": "succeeded"
            }
        ],
        "screenshot": [],
        "singlefile": [],
        "title": [
            {
                "cmd": [
                    "/usr/bin/curl",
                    "--silent",
                    "--location",
                    "--compressed",
                    "--proxy",
                    "socks5://tor-socks-proxy:9150",
                    "--max-time",
                    "60",
                    "--user-agent",
                    "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 ArchiveBox/{VERSION} (+https://github.com/ArchiveBox/ArchiveBox/)",
                    "https://lobste.rs/s/gijhis/unit_testing_principles"
                ],
                "cmd_version": "8.10.1",
                "end_ts": "2025-08-03T01:42:50.836301+00:00",
                "index_texts": null,
                "output": "Unit Testing Principles | Lobsters",
                "pwd": "/data/archive/1754185356.832198",
                "schema": "ArchiveResult",
                "start_ts": "2025-08-03T01:42:50.602115+00:00",
                "status": "succeeded"
            }
        ],
        "wget": []
    },
    "icons": null,
    "is_archived": true,
    "is_static": false,
    "latest": {
        "archive_org": "TimeoutExpired: Command '['/usr/bin/curl', '--silent', '--location', '--compressed', '--proxy', 'socks5://tor-socks-proxy:9150', '--head', '--max-time', '60', '--user-agent', 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 ArchiveBox/{VERSION} (+https://github.com/ArchiveBox/ArchiveBox/)', 'https://web.archive.org/save/https://lobste.rs/s/gijhis/unit_testing_principles']' timed out after 60 seconds",
        "dom": "output.html",
        "favicon": "favicon.ico",
        "git": null,
        "media": "media/",
        "pdf": null,
        "screenshot": null,
        "singlefile": null,
        "title": "Unit Testing Principles | Lobsters",
        "warc": null,
        "wget": null
    },
    "link_dir": "/data/archive/1754185356.832198",
    "newest_archive_date": "2025-08-03T01:43:12.197581+00:00",
    "num_failures": 1,
    "num_outputs": 8,
    "oldest_archive_date": "2025-08-03T01:42:41.560274+00:00",
    "path": "/s/gijhis/unit_testing_principles",
    "schema": "Link",
    "scheme": "https",
    "snapshot_abid": "snp_01K1PSGNME0CA4B8A3016ANVFM",
    "snapshot_id": "f01d6d7e-2bca-46e2-8e1e-8e358caaedf4",
    "sources": [
        "/data/sources/1754185355-import.txt"
    ],
    "tags": null,
    "tags_str": "",
    "timestamp": "1754185356.832198",
    "title": "Unit Testing Principles | Lobsters",
    "url": "https://lobste.rs/s/gijhis/unit_testing_principles"
}