-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ExplanatoryAssertionGroupType Naming #91
Comments
Given that we currently plan to use the name |
Just some food for thought: #1 (comment) |
I agree that we should change the names. They represent the currently used symbols and this is actually configurable. However, renaming ExplanatoryAssertionGroupType to InformationAssertionGroupType only makes sense if we rename ExplanatoryAssertionGroup to InformationAssertionGroup as well. And here I am not sure if this a good name.
InformationAssertionGroup does not tell me what it is for, its too generic IMO. |
You have once again proven how bad my memory is 😄 Unsurprisingly, I still like I think this would also address your second comment, wouldn’t it? Removing the word Most of your examples wouldn’t use It makes sense to my mind. |
To clarify: I think dropping the word “Assertion” from everything that is not actually an assertion already makes sense, even if they still inherit from |
I agree
I prefer HelpReportableGroupType over DebugDetailReportableGroupType
I am not 100% sure but I think it might be we need ReportableGroup as a super type but I also think that we still need ExplanatoryGroup. I'll give this some thoughts later on |
We definitely need a supertype for the group types, because we use |
I guess we need to re-iterate this as it seems I don't have the same intuition about the change as you do. I am interested in how you would like to see things. Following a few more examples. In the end, I would like to see the following reports (I introduced a new bullet point 💡)
|
Once we tackle the alignment in reporting, we will need to look for bullet points with a standard width as it really looks ugly if the numbers or parentheses are slightly shifted. |
Thanks for writing down all those examples! I like your idea of differentiating between messages from the library and messages from the programmer by using ℹ️ or 💡, respectively. I agree with all your examples. My only disagreement is with the properties of exceptions, but as I stated in #738, I can live with it, as long as it is not ℹ️. With the new meaning of ℹ️, this because even more important. I think it is important that we chose good names for the groups representing these bullet points. We should make it as easy as possible for developers to understand what the groups are good for. |
is that something we can influence? I’d expect that the character width is determined by the user’s font 😕 . We could use tabs, which would give as reliable alignment. We would lose control over the width of spacings, though. |
At least a bit. I am only talking about the real bullet points: |
How do all these emojis look on Windows console that does not support UTF-8? |
Good point, so far we did not target windows consoles and as there was never a complaint, I guess most use linux runners in CI? I guess we never got a complaint because most users use intellij and it looks all good on their console. Nevertheless, it's something we should tackle if we have more users who use Windows (but IMO it's not a priority). We plan to introduce colours via ANSI and there we will have a fallback for terminals not supporting ANSI (i.e. also all the Windows consoles). Do you know if this is coupled, in other words, is it enough if we base the emoji fallback on the support for ANSI or should we somehow figure out in another way the (proper) support for UTF-8? I would pre-seen the following ascii icons:
|
That is my case :-/
I guess the only workaround, for now, is to use ASCII |
We currently have
ExplanatoryAssertionGroupType
, as supertype for all group types that add some kind of additional information to an assertion. As of atrium#666, We have these subtypes:ExplanatoryAssertionGroupType
WarningAssertionGroupType
InformationAssertionGroupType
I want to suggest to redo the naming of these group types based on the use cases we found while discussing #9 and #15.
These use cases are:
contains
checkCurrently, we map the use cases as follows:
1 ->
WarningAssertionGroupType
2 ->
ExplanatoryAssertionGroupType
3 ->
InformationAssertionGroupType
I see three issues with the current structure:
i. From my point of view, the names of the types are not a good indication for the use case of the types.
ii. I think that it is odd that
ExplanatoryAssertionGroupType
is a supertype of the other two, although its use case does not really subsum the other two use cases.iii. I think “warning” is a not a good word choice for
WarningAssertionGroupType
, as it is always used in a context where the “warning” is not recoverable, i.e. the assertion will not succeed without fixing the warning. To my mind, a “warning” is something bad, but recoverable.I think we should address these issues. To start the discussion, I suggest the following hierarchy:
InformationAssertionGroupType
(instead ofExplanatoryAssertionGroupType
)RelatedErrorAssertionGroupType
(instead ofWarningAssertionGroupType
)ReasonAssertionGroupType
(instead ofInformationAssertionGroupType
)DebugDetailAssertionGroupType
(new type for use case 2)Most cases where we currently use
ExplanatoryAssertionGroupType
would useDebugDetailAssertionGroupType
. The (new)InformationAssertionGroupType
would only be used for cases that are not covered by the uses cases 1, 2 or 3. Ideally,InformationAssertionGroupType
would only serve as a fallback type that is never used.If we decide to rename the group types, we need to make sure to rename all related helpers as well, like
ExplanatoryGroup
,withExplanatoryAssertion
,withExplanation
, etc. pp.The text was updated successfully, but these errors were encountered: