Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Angularでのテスト戦略

Kitagawa
January 31, 2019

 Angularでのテスト戦略

2019/1/31 Classi AngularNight#1でLTした資料です

Kitagawa

January 31, 2019
Tweet

More Decks by Kitagawa

Other Decks in Technology

Transcript

  1. $0/'*%&/5*"-5PSFUB*OD "MM3JHIU3FTFSWFEɹ 5IF5FTU5SPQIZ ࢀরIUUQTUFTUJOHKBWBTDSJQUDPN IUUQTCMPHLFOUDEPEETDPNXSJUFUFTUTOPUUPPNBOZNPTUMZJOUFHSBUJPOFD⒎GD The Testing Trophy is a

    bottom-to-top professional method for testing web applications. It’s about writing just enough tests—the right tests. It’s not about reaching for 100% coverage.
  2. $0/'*%&/5*"-5PSFUB*OD "MM3JHIU3FTFSWFEɹ 7BMVF $PNQPOFOU )5.- $PNQPOFOU $PNQPOFOU ✔ ✔ ✔

    7BMVF $PNQPOFOU )5.- $PNQPOFOU $PNQPOFOU ✔ *OUFHSBUJPO5FTU 6OJU5FTU 4IBMMPX5FTU 㲈
  3. $0/'*%&/5*"-5PSFUB*OD "MM3JHIU3FTFSWFEɹ εφοϓγϣοτͷςετ͸UI ͕༧ظͤͣมߋ͞Ε͍ͯͳ ͍͔Λ͔֬ΊΔͷʹඇৗʹ༗༻ͳπʔϧͰ͢ɻ A typical snapshot test case

    for a mobile app renders a UI component, takes a snapshot, then compares it to a reference snapshot file stored alongside the test. The test will fail if the two snapshots do not match: either the change is unexpected, or the reference snapshot needs to be updated to the new version of the UI component. 4OBQTIPU5FTUJOH ਐߦத EJWDMBTTIPVS TQBO  TQBO EJW EJWDMBTTIPVS TQBO  TQBO EJW 4OBQTIPU 3FDFJWFE