Skip to content
This repository was archived by the owner on Oct 13, 2022. It is now read-only.
This repository was archived by the owner on Oct 13, 2022. It is now read-only.

テストの改善 #34

@Takeno-hito

Description

@Takeno-hito

test refactor
主に foreach を何回も使っていた所を直したり (phpunit で回数指定できるから要らない、、)
少しメソッドを分割して統合したり

改善項目

  • expectErrorResponse を使って重複した行を大量に削った → #34 テストの改善 #35
  • testMultipleError 内のケースを dataProvider を利用して分割 → #34 テストの改善 #35
  • テスト内で特段の理由がない限り複数回テストをしないようにする #64
    • すでにデータがあった状態でデータを作っても問題が発生してないかも試したいからよく考えた方がいいのかも?
      • メソッドの中で2回以上getなどを叩く事が想定されてないらしいのでそれに沿った形にする
  • その代わりテストの実行回数を2回以上にする
  • テストケースを作るかも? memo: testwith
  • ステータスコードとエラーコードを同時にチェックできるようなassertionを作る
  • 権限チェック

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions