Skip to content

Document the package and cover with tests - #1

Open
alemohamad wants to merge 1 commit into
miolabs:mainfrom
alemohamad:feature/docc_and_tests
Open

Document the package and cover with tests#1
alemohamad wants to merge 1 commit into
miolabs:mainfrom
alemohamad:feature/docc_and_tests

Conversation

@alemohamad

Copy link
Copy Markdown

What this is

Documentation and tests for MIOEntityCore. No behavior changes: every source edit is a comment, and the test suite goes from 2 tests to 41.

  • DocC catalog with a landing page, plus doc comments on every public symbol
  • Tests for MECCache and MECModel
  • Added more tests for MECEntityCache
  • README was expanded for a brief presentation of the package

How the content was arrived at, and why you should push back on it

Most of this is inference. I had no design document. The descriptions come from reading the implementation and from reviewing how a production consumer actually calls it. I turned claims into a test so it is checked rather than assumed, but the framing and the explanations are still my opinions, not a record of anyone's intent.

That means some of it will be wrong in ways only you can see. A few specific places worth a careful look:

  • The two cache systems are described as answering two different questions, grouping a batch versus comparing sets. That is how they seem to be used in practice, but if the original intent was different, the whole landing page follows from it.
  • I don't call anything a bug, as several implementations are probably deliberate decisions whose reasons are not visible in first glance.

Rewrite anything that does not sound right. The aim is that anybody who picks this package up for the first time can work out which of the two caches they want and avoid unintended implementations, so clearer wording beats what I wrote. Correcting a description here will be much cheaper than someone learning it without context later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant