<feed xmlns='http://www.w3.org/2005/Atom'>
<title>pakakeh.go/lib/test/test.go, branch main</title>
<subtitle>Collections of packages and tools for working with Go programming language.</subtitle>
<id>http://git.kilabit.info/pakakeh.go/atom?h=main</id>
<link rel='self' href='http://git.kilabit.info/pakakeh.go/atom?h=main'/>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/'/>
<updated>2026-04-12T15:33:31Z</updated>
<entry>
<title>lib/test: rewrite Assert to use [diff.Unified]</title>
<updated>2026-04-12T15:33:31Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2026-04-12T14:20:40Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=c1a33bead8068e02c34fafb09c5519d5e5c18706'/>
<id>urn:sha1:c1a33bead8068e02c34fafb09c5519d5e5c18706</id>
<content type='text'>
Using diff Unified improve the test output readability when two large
strings are not match.
</content>
</entry>
<entry>
<title>all: replace "interface{}" with "any"</title>
<updated>2025-01-22T18:52:09Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2025-01-22T18:52:09Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=605d847b236dde031a2e387e74298d66a27b5e0a'/>
<id>urn:sha1:605d847b236dde031a2e387e74298d66a27b5e0a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>lib/test: call Helper method inside Assert</title>
<updated>2025-01-22T13:04:15Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2025-01-21T14:39:42Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=b9cff7d8f66d679218d1eaf4b015febbc48abc9e'/>
<id>urn:sha1:b9cff7d8f66d679218d1eaf4b015febbc48abc9e</id>
<content type='text'>
The Helper method mark the Assert function as test helper, which when
printing file and line information, the stack trace from Assert function
will be skipped.
This remove manual lines skipping that previously we have.

</content>
</entry>
<entry>
<title>lib/test: update comment to show link on reflect.Equaler</title>
<updated>2024-12-28T07:41:37Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2024-12-14T15:48:23Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=8f32a86334b513ebb9952efc21ebe11f5e6f06c6'/>
<id>urn:sha1:8f32a86334b513ebb9952efc21ebe11f5e6f06c6</id>
<content type='text'>
</content>
</entry>
<entry>
<title>all: move the repository to "git.sr.ht/~shulhan/pakakeh.go"</title>
<updated>2024-03-02T08:59:46Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2024-03-01T20:07:33Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=901c9803e6f93e0d5ee282f4061309022c46f490'/>
<id>urn:sha1:901c9803e6f93e0d5ee282f4061309022c46f490</id>
<content type='text'>
There are several reasons that why we move from github.com.

First, related to the name of package.
We accidentally name the package with "share" a common word in English
that does not reflect the content of repository.
By moving to other repository, we can rename it to better and unique
name, in this "pakakeh.go".
Pakakeh is Minang word for tools, and ".go" suffix indicate that the
repository related to Go programming language.

Second, supporting open source.
The new repository is hosted under sourcehut.org, the founder is known
to support open source, and all their services are licensed under AGPL,
unlike GitHub that are closed sources.

Third, regarding GitHub CoPilot.
The GitHub Terms of Service [1], allow any public content that are hosted
there granted them to parse the content.
On one side, GitHub helps and flourish the open source, but on another
side have an issues regarding scraping the copyleft license [2].

[1]: https://docs.github.com/en/site-policy/github-terms/github-terms-of-service#4-license-grant-to-us
[2]: https://githubcopilotinvestigation.com
</content>
</entry>
<entry>
<title>lib/test: refactoring, rename TestWriter to BufferWriter</title>
<updated>2023-09-10T19:16:52Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2023-09-10T13:00:39Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=f80218a8023ad2c171901bd422d2a8f6bd155a48'/>
<id>urn:sha1:f80218a8023ad2c171901bd422d2a8f6bd155a48</id>
<content type='text'>
The name TestWriter is considered stutter if its called from external
package, test.TestWriter.

While at it, implement the Error and Errorf in BufferWriter and add
comment to each exported methods.
</content>
</entry>
<entry>
<title>lib/test: update documentation related to Assert and Data</title>
<updated>2023-05-30T16:34:53Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2023-05-30T15:29:07Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=b2619cda05c46175dc4f2e0ae7efbd3dae8b574b'/>
<id>urn:sha1:b2619cda05c46175dc4f2e0ae7efbd3dae8b574b</id>
<content type='text'>
The documentation is based on the article published at
https://kilabit.local/journal/2023/go_test_data/
after reviewing and explain how to use both of them to public.
</content>
</entry>
<entry>
<title>lib/test: use different package for example</title>
<updated>2023-05-25T13:00:00Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2023-05-25T13:00:00Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=83c2863122df9e550406c525cc57dfe5fb9843f2'/>
<id>urn:sha1:83c2863122df9e550406c525cc57dfe5fb9843f2</id>
<content type='text'>
The idea is to prevent using non-exported function in example.
Case in point, in this changes the testWriter is used in example and
not exported which make our test not runnable on public website.
To fix that we export TestWriter with this changes.
</content>
</entry>
<entry>
<title>lib/test: update the Assert comment related to latest changes</title>
<updated>2023-03-12T05:03:29Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2023-03-12T05:03:29Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=9fd56fef39f462caccc614eb12d2a7edccd6c651'/>
<id>urn:sha1:9fd56fef39f462caccc614eb12d2a7edccd6c651</id>
<content type='text'>
While at it, update the CHANGELOG to add that previous changes.
</content>
</entry>
<entry>
<title>lib/test: simplify the string diff output from Assert</title>
<updated>2023-03-02T16:06:28Z</updated>
<author>
<name>Shulhan</name>
<email>ms@kilabit.info</email>
</author>
<published>2023-03-02T15:47:29Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/pakakeh.go/commit/?id=cdd878b72c675a7f1c13e0eb005e610d7b7269dc'/>
<id>urn:sha1:cdd878b72c675a7f1c13e0eb005e610d7b7269dc</id>
<content type='text'>
In the output, instead of using %q we replace it with %s, because printing
string with double quote cause escaping and hard to read
This change may cause difference in white spaces not showed in the
terminal.

In the diff changes, only print the Old and New, without printing each
chunk.
</content>
</entry>
</feed>
