{"id":38451,"date":"2024-11-01T18:17:07","date_gmt":"2024-11-01T18:17:07","guid":{"rendered":"http:\/\/atmokpo.com\/w\/?p=38451"},"modified":"2024-11-26T06:44:18","modified_gmt":"2024-11-26T06:44:18","slug":"fastapi-%ec%84%9c%eb%b2%84%ea%b0%9c%eb%b0%9c-pytest%eb%a5%bc-%ec%9d%b4%ec%9a%a9%ed%95%9c-%eb%8b%a8%ec%9c%84-%ed%85%8c%ec%8a%a4%ed%8a%b8-%eb%b0%8f-%ed%86%b5%ed%95%a9-%ed%85%8c%ec%8a%a4%ed%8a%b8","status":"publish","type":"post","link":"https:\/\/atmokpo.com\/w\/38451\/","title":{"rendered":"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8"},"content":{"rendered":"<p><body><\/p>\n<p>FastAPI\ub294 \ud604\ub300\uc758 \ube60\ub974\uace0 \uac04\uacb0\ud55c \uc6f9 \uc560\ud50c\ub9ac\ucf00\uc774\uc158 \uc11c\ubc84\ub97c \uac1c\ubc1c\ud558\uae30 \uc704\ud55c \ud504\ub808\uc784\uc6cc\ud06c\uc785\ub2c8\ub2e4. Python 3.7 \uc774\uc0c1\uc5d0\uc11c \uc0ac\uc6a9\ud560 \uc218 \uc788\uc73c\uba70, \ube44\ub3d9\uae30 \ud504\ub85c\uadf8\ub798\ubc0d\uc744 \uc9c0\uc6d0\ud558\uc5ec \ub192\uc740 \uc131\ub2a5\uc744 \uc790\ub791\ud569\ub2c8\ub2e4. \uc774\ubc88 \uae00\uc5d0\uc11c\ub294 FastAPI\ub97c \uc774\uc6a9\ud574 \uac04\ub2e8\ud55c \uc11c\ubc84\ub97c \uac1c\ubc1c\ud558\uace0, pytest\ub97c \uc0ac\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 \ubc29\ubc95\uc5d0 \ub300\ud574 \uc2ec\uce35\uc801\uc73c\ub85c \ub2e4\ub904 \ubcf4\uaca0\uc2b5\ub2c8\ub2e4.<\/p>\n<h2>1. FastAPI \uac1c\uc694<\/h2>\n<p>FastAPI\ub294 \ube44\ub3d9\uae30 \uc6f9 \uc11c\ubc84 \uac1c\ubc1c\uc5d0 \ucd5c\uc801\ud654\ub41c Python \ud504\ub808\uc784\uc6cc\ud06c\ub85c, RESTful API\ub97c \uc27d\uac8c \uad6c\ucd95\ud560 \uc218 \uc788\ub294 \uae30\ub2a5\uc744 \uc81c\uacf5\ud569\ub2c8\ub2e4. \ub370\uc774\ud130 \uac80\uc99d, \ubb38\uc11c\ud654, \uc758\uc874\uc131 \uc8fc\uc785 \ub4f1\uc758 \uae30\ub2a5\uc744 \ub0b4\uc7a5\ud558\uace0 \uc788\uc5b4, \ub2a5\ub960\uc801\uc778 \uac1c\ubc1c\uc744 \uac00\ub2a5\ud558\uac8c \ud569\ub2c8\ub2e4.<\/p>\n<h3>1.1. FastAPI\uc758 \uc8fc\uc694 \ud2b9\uc9d5<\/h3>\n<ul>\n<li><strong>\uace0\uc18d:<\/strong> ASGI \uc11c\ubc84\ub97c \uae30\ubc18\uc73c\ub85c \ube44\ub3d9\uae30 \ucc98\ub9ac\uac00 \uac00\ub2a5\ud558\uc5ec \ub192\uc740 \uc131\ub2a5\uc744 \uc790\ub791\ud569\ub2c8\ub2e4.<\/li>\n<li><strong>\uc790\ub3d9 \ubb38\uc11c\ud654:<\/strong> Swagger UI \ubc0f ReDoc\uc744 \ud1b5\ud574 API \ubb38\uc11c\ub97c \uc790\ub3d9\uc73c\ub85c \uc0dd\uc131\ud569\ub2c8\ub2e4.<\/li>\n<li><strong>\ub370\uc774\ud130 \uac80\uc99d:<\/strong> Pydantic\uc744 \uc774\uc6a9\ud558\uc5ec \ub370\uc774\ud130\uc758 \uc720\ud6a8\uc131\uc744 \uac80\uc0ac\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.<\/li>\n<li><strong>\ud655\uc7a5\uc131:<\/strong> \ucee4\uc2a4\ud130\ub9c8\uc774\uc9d5\uc774 \uc6a9\uc774\ud558\uba70, \ub2e4\ub978 \ud504\ub808\uc784\uc6cc\ud06c\uc640\uc758 \ud1b5\ud569\uc774 \uc27d\uc2b5\ub2c8\ub2e4.<\/li>\n<\/ul>\n<h2>2. FastAPI \uc11c\ubc84 \uad6c\ucd95<\/h2>\n<p>\uc774\uc81c FastAPI\ub97c \uc0ac\uc6a9\ud558\uc5ec \uac04\ub2e8\ud55c RESTful API \uc11c\ubc84\ub97c \ub9cc\ub4e4\uc5b4 \ubcf4\uaca0\uc2b5\ub2c8\ub2e4. \uc774 \uc608\uc81c\uc5d0\uc11c\ub294 \uc0ac\uc6a9\uc790 \uc815\ubcf4\ub97c \uad00\ub9ac\ud558\ub294 API\ub97c \uad6c\ucd95\ud560 \uac83\uc785\ub2c8\ub2e4.<\/p>\n<h3>2.1. FastAPI \uc124\uce58\ud558\uae30<\/h3>\n<pre><code>pip install fastapi uvicorn<\/code><\/pre>\n<h3>2.2. API \ucf54\ub4dc \uc791\uc131\ud558\uae30<\/h3>\n<p>\ub2e4\uc74c\uc740 \uc0ac\uc6a9\uc790 \uc815\ubcf4\ub97c \ub2e4\ub8e8\ub294 API\uc758 \uc0d8\ud50c \ucf54\ub4dc\uc785\ub2c8\ub2e4. \uc774 \ucf54\ub4dc\ub294 GET, POST, PUT, DELETE \uba54\uc18c\ub4dc\ub97c \uc9c0\uc6d0\ud569\ub2c8\ub2e4.<\/p>\n<pre><code>from fastapi import FastAPI\nfrom pydantic import BaseModel\nfrom typing import List\n\napp = FastAPI()\n\nclass User(BaseModel):\n    id: int\n    name: str\n    age: int\n\nusers = []\n\n@app.post(\"\/users\/\", response_model=User)\ndef create_user(user: User):\n    users.append(user)\n    return user\n\n@app.get(\"\/users\/\", response_model=List[User])\ndef read_users():\n    return users\n\n@app.get(\"\/users\/{user_id}\", response_model=User)\ndef read_user(user_id: int):\n    return next((user for user in users if user.id == user_id), None)\n\n@app.put(\"\/users\/{user_id}\", response_model=User)\ndef update_user(user_id: int, user: User):\n    for i, u in enumerate(users):\n        if u.id == user_id:\n            users[i] = user\n            return user\n    return None\n\n@app.delete(\"\/users\/{user_id}\")\ndef delete_user(user_id: int):\n    global users\n    users = [user for user in users if user.id != user_id]\n    return {\"message\": \"User deleted successfully\"} \n<\/code><\/pre>\n<h3>2.3. \uc2e4\ud589\ud558\uae30<\/h3>\n<p>\uc11c\ubc84\ub97c \uc2e4\ud589\ud558\uae30 \uc704\ud574 \ub2e4\uc74c \uba85\ub839\uc5b4\ub97c \uc785\ub825\ud569\ub2c8\ub2e4.<\/p>\n<pre><code>uvicorn main:app --reload<\/code><\/pre>\n<p>\uc774\uc81c <code>http:\/\/127.0.0.1:8000\/docs<\/code>\ub97c \ud1b5\ud574 Swagger UI\uc5d0\uc11c API\ub97c \ud14c\uc2a4\ud2b8\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.<\/p>\n<h2>3. \ud14c\uc2a4\ud2b8\ud558\uae30<\/h2>\n<p>\uc774\uc81c \uc791\uc131\ud55c API\ub97c \ud14c\uc2a4\ud2b8\ud558\uae30 \uc704\ud574 <strong>pytest<\/strong>\ub97c \uc0ac\uc6a9\ud558\uaca0\uc2b5\ub2c8\ub2e4. <strong>pytest<\/strong>\ub294 Python\uc758 \uac15\ub825\ud55c \ud14c\uc2a4\ud2b8 \ud504\ub808\uc784\uc6cc\ud06c\ub85c, \uac04\ub2e8\ud558\uace0 \uc6b0\uc544\ud55c \ubb38\ubc95\uc73c\ub85c \ud14c\uc2a4\ud2b8\ub97c \uc791\uc131\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.<\/p>\n<h3>3.1. pytest \uc124\uce58\ud558\uae30<\/h3>\n<pre><code>pip install pytest httpx<\/code><\/pre>\n<h3>3.2. \ud14c\uc2a4\ud2b8 \ucf54\ub4dc \uc791\uc131\ud558\uae30<\/h3>\n<p>\ub2e4\uc74c\uc740 FastAPI \uc11c\ubc84\uc5d0 \ub300\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 \uc0d8\ud50c \ucf54\ub4dc\uc785\ub2c8\ub2e4.<\/p>\n<pre><code>from fastapi.testclient import TestClient\nfrom main import app\n\nclient = TestClient(app)\n\ndef test_create_user():\n    response = client.post(\"\/users\/\", json={\"id\": 1, \"name\": \"Alice\", \"age\": 30})\n    assert response.status_code == 200\n    assert response.json() == {\"id\": 1, \"name\": \"Alice\", \"age\": 30}\n\ndef test_read_users():\n    response = client.get(\"\/users\/\")\n    assert response.status_code == 200\n    assert len(response.json()) == 1\n\ndef test_read_user():\n    response = client.get(\"\/users\/1\")\n    assert response.status_code == 200\n    assert response.json() == {\"id\": 1, \"name\": \"Alice\", \"age\": 30}\n\ndef test_update_user():\n    response = client.put(\"\/users\/1\", json={\"id\": 1, \"name\": \"Bob\", \"age\": 25})\n    assert response.status_code == 200\n    assert response.json() == {\"id\": 1, \"name\": \"Bob\", \"age\": 25}\n\ndef test_delete_user():\n    response = client.delete(\"\/users\/1\")\n    assert response.status_code == 200\n    assert response.json() == {\"message\": \"User deleted successfully\"}\n\n    response = client.get(\"\/users\/\")\n    assert len(response.json()) == 0\n<\/code><\/pre>\n<h3>3.3. \ud14c\uc2a4\ud2b8 \uc2e4\ud589\ud558\uae30<\/h3>\n<p>\uc791\uc131\ud55c \ud14c\uc2a4\ud2b8\ub97c \uc2e4\ud589\ud558\uae30 \uc704\ud574 \ub2e4\uc74c \uba85\ub839\uc5b4\ub97c \uc785\ub825\ud569\ub2c8\ub2e4.<\/p>\n<pre><code>pytest<\/code><\/pre>\n<p>\ud14c\uc2a4\ud2b8\uac00 \uc131\uacf5\uc801\uc73c\ub85c \uc9c4\ud589\ub41c\ub2e4\uba74 \ubb38\uc81c\uc5c6\uc774 FastAPI \uc11c\ubc84\uac00 \uc798 \uc791\ub3d9\ud558\uace0 \uc788\ub2e4\ub294 \uac83\uc785\ub2c8\ub2e4. \uac01 \ud14c\uc2a4\ud2b8 \ucf00\uc774\uc2a4\ub294 API\uc758 \uac01 \uae30\ub2a5\uc744 \uac80\uc99d\ud558\uace0 \uc788\uc2b5\ub2c8\ub2e4.<\/p>\n<h2>4. \uacb0\ub860<\/h2>\n<p>\uc774\ubc88 \ud3ec\uc2a4\ud2b8\uc5d0\uc11c\ub294 FastAPI\ub97c \uc0ac\uc6a9\ud558\uc5ec \uac04\ub2e8\ud55c RESTful API \uc11c\ubc84\ub97c \uad6c\ucd95\ud558\uace0, <strong>pytest<\/strong>\ub97c \uc774\uc6a9\ud558\uc5ec \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8\ub97c \uc218\ud589\ud558\ub294 \ubc29\ubc95\uc5d0 \ub300\ud574 \uc54c\uc544\ubcf4\uc558\uc2b5\ub2c8\ub2e4. FastAPI\ub294 \uac04\ud3b8\ud558\uba74\uc11c\ub3c4 \uac15\ub825\ud55c \uae30\ub2a5\uc744 \uc81c\uacf5\ud558\ubbc0\ub85c, \ubcf5\uc7a1\ud55c \uc560\ud50c\ub9ac\ucf00\uc774\uc158\uc744 \uac1c\ubc1c\ud558\ub354\ub77c\ub3c4 \uc548\uc815\uc801\uc778 \uc11c\ube44\uc2a4 \uc6b4\uc601\uc774 \uac00\ub2a5\ud569\ub2c8\ub2e4. \ub2e4\uc74c \ud3ec\uc2a4\ud2b8\uc5d0\uc11c \ub354 \ub9ce\uc740 FastAPI\uc758 \uae30\ub2a5\uacfc \ud14c\uc2a4\ud2b8 \ubc29\ubc95\uc5d0 \ub300\ud574 \ub2e4\ub8e8\uc5b4 \ubcf4\uaca0\uc2b5\ub2c8\ub2e4.<\/p>\n<p><\/body><\/p>\n","protected":false},"excerpt":{"rendered":"<p>FastAPI\ub294 \ud604\ub300\uc758 \ube60\ub974\uace0 \uac04\uacb0\ud55c \uc6f9 \uc560\ud50c\ub9ac\ucf00\uc774\uc158 \uc11c\ubc84\ub97c \uac1c\ubc1c\ud558\uae30 \uc704\ud55c \ud504\ub808\uc784\uc6cc\ud06c\uc785\ub2c8\ub2e4. Python 3.7 \uc774\uc0c1\uc5d0\uc11c \uc0ac\uc6a9\ud560 \uc218 \uc788\uc73c\uba70, \ube44\ub3d9\uae30 \ud504\ub85c\uadf8\ub798\ubc0d\uc744 \uc9c0\uc6d0\ud558\uc5ec \ub192\uc740 \uc131\ub2a5\uc744 \uc790\ub791\ud569\ub2c8\ub2e4. \uc774\ubc88 \uae00\uc5d0\uc11c\ub294 FastAPI\ub97c \uc774\uc6a9\ud574 \uac04\ub2e8\ud55c \uc11c\ubc84\ub97c \uac1c\ubc1c\ud558\uace0, pytest\ub97c \uc0ac\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 \ubc29\ubc95\uc5d0 \ub300\ud574 \uc2ec\uce35\uc801\uc73c\ub85c \ub2e4\ub904 \ubcf4\uaca0\uc2b5\ub2c8\ub2e4. 1. FastAPI \uac1c\uc694 FastAPI\ub294 \ube44\ub3d9\uae30 \uc6f9 \uc11c\ubc84 \uac1c\ubc1c\uc5d0 \ucd5c\uc801\ud654\ub41c Python \ud504\ub808\uc784\uc6cc\ud06c\ub85c, RESTful API\ub97c \uc27d\uac8c &hellip; <a href=\"https:\/\/atmokpo.com\/w\/38451\/\" class=\"more-link\">\ub354 \ubcf4\uae30<span class=\"screen-reader-text\"> &#8220;FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[183],"tags":[],"class_list":["post-38451","post","type-post","status-publish","format-standard","hentry","category-fastapi"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/atmokpo.com\/w\/38451\/\" \/>\n<meta property=\"og:locale\" content=\"ko_KR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\" \/>\n<meta property=\"og:description\" content=\"FastAPI\ub294 \ud604\ub300\uc758 \ube60\ub974\uace0 \uac04\uacb0\ud55c \uc6f9 \uc560\ud50c\ub9ac\ucf00\uc774\uc158 \uc11c\ubc84\ub97c \uac1c\ubc1c\ud558\uae30 \uc704\ud55c \ud504\ub808\uc784\uc6cc\ud06c\uc785\ub2c8\ub2e4. Python 3.7 \uc774\uc0c1\uc5d0\uc11c \uc0ac\uc6a9\ud560 \uc218 \uc788\uc73c\uba70, \ube44\ub3d9\uae30 \ud504\ub85c\uadf8\ub798\ubc0d\uc744 \uc9c0\uc6d0\ud558\uc5ec \ub192\uc740 \uc131\ub2a5\uc744 \uc790\ub791\ud569\ub2c8\ub2e4. \uc774\ubc88 \uae00\uc5d0\uc11c\ub294 FastAPI\ub97c \uc774\uc6a9\ud574 \uac04\ub2e8\ud55c \uc11c\ubc84\ub97c \uac1c\ubc1c\ud558\uace0, pytest\ub97c \uc0ac\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 \ubc29\ubc95\uc5d0 \ub300\ud574 \uc2ec\uce35\uc801\uc73c\ub85c \ub2e4\ub904 \ubcf4\uaca0\uc2b5\ub2c8\ub2e4. 1. FastAPI \uac1c\uc694 FastAPI\ub294 \ube44\ub3d9\uae30 \uc6f9 \uc11c\ubc84 \uac1c\ubc1c\uc5d0 \ucd5c\uc801\ud654\ub41c Python \ud504\ub808\uc784\uc6cc\ud06c\ub85c, RESTful API\ub97c \uc27d\uac8c &hellip; \ub354 \ubcf4\uae30 &quot;FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8&quot;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/atmokpo.com\/w\/38451\/\" \/>\n<meta property=\"og:site_name\" content=\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\" \/>\n<meta property=\"article:published_time\" content=\"2024-11-01T18:17:07+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-11-26T06:44:18+00:00\" \/>\n<meta name=\"author\" content=\"root\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@bebubo4\" \/>\n<meta name=\"twitter:site\" content=\"@bebubo4\" \/>\n<meta name=\"twitter:label1\" content=\"\uae00\uc4f4\uc774\" \/>\n\t<meta name=\"twitter:data1\" content=\"root\" \/>\n\t<meta name=\"twitter:label2\" content=\"\uc608\uc0c1 \ub418\ub294 \ud310\ub3c5 \uc2dc\uac04\" \/>\n\t<meta name=\"twitter:data2\" content=\"2\ubd84\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/atmokpo.com\/w\/38451\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/atmokpo.com\/w\/38451\/\"},\"author\":{\"name\":\"root\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7\"},\"headline\":\"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8\",\"datePublished\":\"2024-11-01T18:17:07+00:00\",\"dateModified\":\"2024-11-26T06:44:18+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/atmokpo.com\/w\/38451\/\"},\"wordCount\":47,\"publisher\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\"},\"articleSection\":[\"FastAPI\uc11c\ubc84\uac1c\ubc1c\"],\"inLanguage\":\"ko-KR\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/atmokpo.com\/w\/38451\/\",\"url\":\"https:\/\/atmokpo.com\/w\/38451\/\",\"name\":\"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"isPartOf\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#website\"},\"datePublished\":\"2024-11-01T18:17:07+00:00\",\"dateModified\":\"2024-11-26T06:44:18+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/atmokpo.com\/w\/38451\/#breadcrumb\"},\"inLanguage\":\"ko-KR\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/atmokpo.com\/w\/38451\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/atmokpo.com\/w\/38451\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\ud648\",\"item\":\"https:\/\/atmokpo.com\/w\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/atmokpo.com\/w\/#website\",\"url\":\"https:\/\/atmokpo.com\/w\/\",\"name\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/atmokpo.com\/w\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ko-KR\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\",\"name\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"url\":\"https:\/\/atmokpo.com\/w\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ko-KR\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png\",\"contentUrl\":\"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png\",\"width\":400,\"height\":400,\"caption\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\"},\"image\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/x.com\/bebubo4\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7\",\"name\":\"root\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ko-KR\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g\",\"caption\":\"root\"},\"sameAs\":[\"http:\/\/atmokpo.com\/w\"],\"url\":\"https:\/\/atmokpo.com\/w\/author\/root\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/atmokpo.com\/w\/38451\/","og_locale":"ko_KR","og_type":"article","og_title":"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","og_description":"FastAPI\ub294 \ud604\ub300\uc758 \ube60\ub974\uace0 \uac04\uacb0\ud55c \uc6f9 \uc560\ud50c\ub9ac\ucf00\uc774\uc158 \uc11c\ubc84\ub97c \uac1c\ubc1c\ud558\uae30 \uc704\ud55c \ud504\ub808\uc784\uc6cc\ud06c\uc785\ub2c8\ub2e4. Python 3.7 \uc774\uc0c1\uc5d0\uc11c \uc0ac\uc6a9\ud560 \uc218 \uc788\uc73c\uba70, \ube44\ub3d9\uae30 \ud504\ub85c\uadf8\ub798\ubc0d\uc744 \uc9c0\uc6d0\ud558\uc5ec \ub192\uc740 \uc131\ub2a5\uc744 \uc790\ub791\ud569\ub2c8\ub2e4. \uc774\ubc88 \uae00\uc5d0\uc11c\ub294 FastAPI\ub97c \uc774\uc6a9\ud574 \uac04\ub2e8\ud55c \uc11c\ubc84\ub97c \uac1c\ubc1c\ud558\uace0, pytest\ub97c \uc0ac\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 \ubc29\ubc95\uc5d0 \ub300\ud574 \uc2ec\uce35\uc801\uc73c\ub85c \ub2e4\ub904 \ubcf4\uaca0\uc2b5\ub2c8\ub2e4. 1. FastAPI \uac1c\uc694 FastAPI\ub294 \ube44\ub3d9\uae30 \uc6f9 \uc11c\ubc84 \uac1c\ubc1c\uc5d0 \ucd5c\uc801\ud654\ub41c Python \ud504\ub808\uc784\uc6cc\ud06c\ub85c, RESTful API\ub97c \uc27d\uac8c &hellip; \ub354 \ubcf4\uae30 \"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8\"","og_url":"https:\/\/atmokpo.com\/w\/38451\/","og_site_name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","article_published_time":"2024-11-01T18:17:07+00:00","article_modified_time":"2024-11-26T06:44:18+00:00","author":"root","twitter_card":"summary_large_image","twitter_creator":"@bebubo4","twitter_site":"@bebubo4","twitter_misc":{"\uae00\uc4f4\uc774":"root","\uc608\uc0c1 \ub418\ub294 \ud310\ub3c5 \uc2dc\uac04":"2\ubd84"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/atmokpo.com\/w\/38451\/#article","isPartOf":{"@id":"https:\/\/atmokpo.com\/w\/38451\/"},"author":{"name":"root","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7"},"headline":"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8","datePublished":"2024-11-01T18:17:07+00:00","dateModified":"2024-11-26T06:44:18+00:00","mainEntityOfPage":{"@id":"https:\/\/atmokpo.com\/w\/38451\/"},"wordCount":47,"publisher":{"@id":"https:\/\/atmokpo.com\/w\/#organization"},"articleSection":["FastAPI\uc11c\ubc84\uac1c\ubc1c"],"inLanguage":"ko-KR"},{"@type":"WebPage","@id":"https:\/\/atmokpo.com\/w\/38451\/","url":"https:\/\/atmokpo.com\/w\/38451\/","name":"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8 - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","isPartOf":{"@id":"https:\/\/atmokpo.com\/w\/#website"},"datePublished":"2024-11-01T18:17:07+00:00","dateModified":"2024-11-26T06:44:18+00:00","breadcrumb":{"@id":"https:\/\/atmokpo.com\/w\/38451\/#breadcrumb"},"inLanguage":"ko-KR","potentialAction":[{"@type":"ReadAction","target":["https:\/\/atmokpo.com\/w\/38451\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/atmokpo.com\/w\/38451\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\ud648","item":"https:\/\/atmokpo.com\/w\/en\/"},{"@type":"ListItem","position":2,"name":"FastAPI \uc11c\ubc84\uac1c\ubc1c, pytest\ub97c \uc774\uc6a9\ud55c \ub2e8\uc704 \ud14c\uc2a4\ud2b8 \ubc0f \ud1b5\ud569 \ud14c\uc2a4\ud2b8"}]},{"@type":"WebSite","@id":"https:\/\/atmokpo.com\/w\/#website","url":"https:\/\/atmokpo.com\/w\/","name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","description":"","publisher":{"@id":"https:\/\/atmokpo.com\/w\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/atmokpo.com\/w\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ko-KR"},{"@type":"Organization","@id":"https:\/\/atmokpo.com\/w\/#organization","name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","url":"https:\/\/atmokpo.com\/w\/","logo":{"@type":"ImageObject","inLanguage":"ko-KR","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/","url":"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png","contentUrl":"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png","width":400,"height":400,"caption":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8"},"image":{"@id":"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/x.com\/bebubo4"]},{"@type":"Person","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7","name":"root","image":{"@type":"ImageObject","inLanguage":"ko-KR","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g","caption":"root"},"sameAs":["http:\/\/atmokpo.com\/w"],"url":"https:\/\/atmokpo.com\/w\/author\/root\/"}]}},"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[],"_links":{"self":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/38451","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/comments?post=38451"}],"version-history":[{"count":1,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/38451\/revisions"}],"predecessor-version":[{"id":38452,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/38451\/revisions\/38452"}],"wp:attachment":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/media?parent=38451"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/categories?post=38451"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/tags?post=38451"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}