exercism / exercism/cpp

doctor-data task 4 "get_older_bob" is confusing

オープン
#878 コメント 3 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
C++
スター
290
フォーク
244
PR マージ指標
30日以内にマージされた PR はありません

説明

I think in this case either the test case is to simple or the function name is misleading.
The test only checks if the function returns the string "Bob".
Out of two Vessels it seems to return the name of the one called "Bob".

The function name suggests that in the case of two Bob Vessels it would return the older one.
As it only returns the name there is no way to check though.

Also what happens when none of the inputs is a Vessel called "Bob"?

With all accessible information the most sensible solution to the task here might be to ignore the inputs and always return "Bob".

I think this function needs more test cases and/or should be ranamed.

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。