Skip to content
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.

課題集

Yuya Tanaka edited this page Apr 11, 2014 · 7 revisions

feature/add_hello_world

  • perl script/hello_world.pl

    • Hello, ruby world??
  • Hello, perl world!に直してテストを通してください

    • prove -r t
  • commit messageをrubyからperlに書き換えてください

add_hello_worldの模範解答

feature/s_ocial

  • 直前のcommitにデバッグコードが紛れた
  • vimとかで編集せずに直してください
    • level1: git reset HEAD~から開始
    • level2: git checkout HEAD~ ./から開始
    • ヒント:git add/reset -p, tig status
$ prove t/lib/MySocial.t
t/lib/MySocial.t .. MySocial loaded at lib/MySocial.pm line 5.
  • tig statusでEnterで差分を開き、該当箇所でuキーでstage/unstage

s_ocialの模範解答

feature/calculate_fibo_*

calculate_fibo_*の模範解答

feature/add_fizzbuzz_test

  • FizzBuzzモジュールのブランチですが中途半端

  • git log見るとすごいので歴史を整理したい

  • branch名がtestになっちゃってるのでgit branch -mで直そう

  • なぜかprove t/lib/MyFibo.tがコケる

    • まずは歴史が消える前にtestが通るように修正しよう
    • git bisectでテストがどのcommitから落ちるようになったか分析
    • Qiitaの記事などを見てみよう
  • git rebase -iで整理しよう

add_fizzbuzz_testの模範解答