Skip to content
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

テストデータにアイコンが小さい画像のユーザーを追加 #3660

Merged
merged 3 commits into from
Dec 6, 2021

Conversation

nga20167304
Copy link
Contributor

@nga20167304 nga20167304 commented Dec 3, 2021

issue: #3615

概要

テストデータに小さい画像のアイコンを登録しているユーザーを追加する

使用する画像

photos-icon
使用する画像が48x 48というサイズがあるので、アイコンのサイズ(88x 88)より小さいのでこの画像を使用しました。

追加後

thuyngaという名前のユーザーを追加しました。
スクリーンショット 2021-12-03 10 16 13

注意点

スクリーンショット 2021-12-03 11 23 52

Binary file not shown.が表示され、追加分の画像が表示されませんが、以上の画像のように確認ができます!

@nga20167304
Copy link
Contributor Author

@Ichiyo14
お手数ですが、お時間のある際にこちらのレビューをお願いします!🙏

@Ichiyo14
Copy link
Contributor

Ichiyo14 commented Dec 3, 2021

@nga20167304
現在、私は「開発に参加して PR を送りマージする」のプラクティスを終えているので、申し訳ないのですが、他の方にレビューを振っていただければと思います!
よろしくお願いします!

@nga20167304
Copy link
Contributor Author

nga20167304 commented Dec 3, 2021

@Ichiyo14
返事ありがとうございます。
他の方にレビューを振ってみます〜
よろしくお願い致します。

@nga20167304
Copy link
Contributor Author

@komagata
どうすればいいでしょうか。他の方にレビューお願いします。

@machida machida removed the request for review from Ichiyo14 December 3, 2021 07:57
@machida
Copy link
Member

machida commented Dec 3, 2021

@nga20167304

https://github.com/fjordllc/bootcamp/wiki/%E3%81%B5%E3%82%8A%E3%81%8B%E3%81%88%E3%82%8A%E3%83%BB%E8%A8%88%E7%94%BB%E3%83%9F%E3%83%BC%E3%83%86%E3%82%A3%E3%83%B3%E3%82%B02021%E5%B9%B412%E6%9C%8801%E6%97%A5
これが前回のMTGの議事録になるのですが、ここにメンバー一覧があるので、ここからレビュワーを選んでくださいー🙏

@nga20167304
Copy link
Contributor Author

@machida
ご指導ありがとうございます。

@nga20167304
Copy link
Contributor Author

@ShotaTsuru
お手数ですが、お時間のある際にこちらのレビューをよろしでしょうでしょうか。🙏

Copy link
Contributor

@ShotaTsuru ShotaTsuru left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nga20167304
ファイルの画像がrails db:seedでサンプルユーザーが作られた際に添付できておりませんので修正をお願い致します🙇‍♂️

userの画像添付に関してはkomagataさんやmachidaさんの画像がどのように添付されているか調査してみると判明するかと思います!

探し方としては、

  1. komagataさんの画像がどこに保存されているかを調べる。
  2. その画像がどのコードによって添付されているかを調べる。大抵の場合そのフォルダ名がパスとして使用されているので検索をかけると出てきます。
  3. 添付されている振る舞いがあるコードを見て自分の実装をどのようにすればいいか推測する。

のような流れで実装の方法が見つかるかと思います。

まず調査の仕方などからお伝えできればと思い段階を追って説明しておりますのでご了承くださいませ。
もし不明な点があれば再度お尋ねいただければと思います!!🙇‍♂️🙇‍♂️🙇‍♂️

yml内の実装は概ね大丈夫かと思います。ただ、user要素内のfeacebook urlなどは架空のものを使用したりするほうがいいかもしれません。

@nga20167304
Copy link
Contributor Author

@ShotaTsuru
レビューとヒントありがとうございます。
setup.dbファイルにattach_user_avatar!メソッドを見つけました。
それで、添付の画像の名前を変更しました。いかがでしょうか。
再レビューお願いします。:bow:

Copy link
Contributor

@ShotaTsuru ShotaTsuru left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nga20167304
ヒントの参照並びに、修正ありがとうございます!😊
開発環境でサーバーを立ち上げて再度ユーザー一覧で確認したところ、
現状courseの情報がnilとエラーが出てしまいます。

コンフリクト修正時に必要な登録情報が欠けてしまったため、アカウントにログインもできないようです。

コンフリクト解消前の情報に書き換えdb:resetすると正しくアカウントにもログインができましたので現在のuser情報とコンフリクト前のコミットのuser情報を比較して差分をなくしていただければ解消するかと思います!

@nga20167304 nga20167304 force-pushed the feature/add_user_small_icon_in_test_data branch from bf4d559 to 8047175 Compare December 3, 2021 15:07
@nga20167304
Copy link
Contributor Author

@ShotaTsuru
何度もレビューありがとうございます。
コンフリクトを誤って修正しましたので、ShotaTsuru さんにご迷惑をかけました。申し訳ありません。:bow:
お手数ですが、レビューお願い致します。:bow:

Copy link
Contributor

@ShotaTsuru ShotaTsuru left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nga20167304
修正ありがとうございます!
間違うことは良いと思いますし、僕もよく間違えるので謝らないでください〜🙇‍♂️🙇‍♂️
動作確認が確認できました!LGTMです😊😊
補足で足すとすれば、descriptionの項目に今回に、ユーザーが何のテストユーザーなのかを説明してあると、今後使用する開発者が何のためのデータかがわかるかと思います!
項目としてマストな部分かは自分では決めかねるので、
あとはkomagataさんにレビューを依頼いただければと思います!

@nga20167304
Copy link
Contributor Author

@komagata
ShotaTsuru さんが出したdescriptionの項目についていかがでしょうか。
ShotaTsuru さんが approved したのでレビューお願い致します。:bow:

@nga20167304
Copy link
Contributor Author

@ShotaTsuru
レビューありがとうございます。:bow:

@komagata
Copy link
Member

komagata commented Dec 4, 2021

@nga20167304 (CC: @ShotaTsuru ) 確かに @ShotaTsuru さんのおっしゃるように、何のためのユーザーなのかDescriptionかymlにコメントとして書いておくていいかもです!

@nga20167304 nga20167304 force-pushed the feature/add_user_small_icon_in_test_data branch from d8ae6be to f5f6d50 Compare December 5, 2021 01:55
@nga20167304
Copy link
Contributor Author

@komagata
追加したので、ご確認お願い致します。:bow:

Copy link
Member

@komagata komagata left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

確認しました、OKですー🙆‍♂️

@komagata komagata merged commit abcb59b into main Dec 6, 2021
@komagata komagata deleted the feature/add_user_small_icon_in_test_data branch December 6, 2021 07:02
@github-actions github-actions bot mentioned this pull request Dec 6, 2021
21 tasks
@nga20167304 nga20167304 self-assigned this Dec 9, 2021
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.

小さい画像のアイコンを登録しているテストユーザーがほしい
5 participants