<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>atotto</author_name>
  <author_url>https://blog.hatena.ne.jp/atotto/</author_url>
  <blog_title>memoメモ</blog_title>
  <blog_url>https://atotto.hatenadiary.jp/</blog_url>
  <categories>
    <anon>golang</anon>
    <anon>Testing</anon>
  </categories>
  <description>Go言語でパッケージのテストを書く時に、プライベートな関数（隠蔽した関数）や定数を呼び出したいことがたまにあります。 これを実現する方法をメモ。 プライベートって？ パッケージの内容は以下のような構成になっているとします： eg.go eg_test.go ここで： eg.go： package eg import () func foo() string { return &quot;foo&quot; } という実装があります。関数名のはじまりを小文字fooにし、意図的に関数を外部から隠蔽しています。これでプライベートになります。（というか、基本は小文字で隠蔽し、公開したい場合は大文字にするといった使い方にな…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fatotto.hatenadiary.jp%2Fentry%2F2013%2F01%2F19%2F112012&quot; title=&quot;Go言語のパッケージのテストでプライベートな関数や変数を呼び出すには - memoメモ&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>2013-01-19 11:20:12</published>
  <title>Go言語のパッケージのテストでプライベートな関数や変数を呼び出すには</title>
  <type>rich</type>
  <url>https://atotto.hatenadiary.jp/entry/2013/01/19/112012</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
