<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>yuta-nakata</author_name>
  <author_url>https://blog.hatena.ne.jp/yuta-nakata/</author_url>
  <blog_title>Yuta NakataのBlog</blog_title>
  <blog_url>https://www.yuta-nakata.net/</blog_url>
  <categories>
    <anon>Python</anon>
  </categories>
  <description>背景 テストコードを書いてください このときにどんなテストコードを書けばいいでしょうか？ 具体例をベースにテストケースの考え方について、本記事では考えます。 テストの種類 テストには、 単体テスト 結合テスト システムテスト 等があります。 ここでは、最も簡単な単体テストについて、取り上げます。 具体例 以下のような関数があります。 このテストケースは何が考えられるでしょうか？ def double_and_get_index(value: int) -&gt; str: if not type(value) is int: raise Exception(&quot;Please Int Value&quot;) v…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fwww.yuta-nakata.net%2Fentry%2F2024%2F07%2F25%2F220545&quot; title=&quot;pytestで考えるテストケース - Yuta NakataのBlog&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2024-07-25 22:05:45</published>
  <title>pytestで考えるテストケース</title>
  <type>rich</type>
  <url>https://www.yuta-nakata.net/entry/2024/07/25/220545</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
