원문: https://jestjs.io/docs/en/asynchronous버전: Jest 23.6번역일: 2018-11-08※ 내용숙지가 완벽하지 않은 번역이라, 원문을 함께 둠Testing Asynchronous CodeIt's common in JavaScript for code to run asynchronously. When you have code that runs asynchronously, Jest needs to know when the code it is testing has completed, before it can move on to another test. Jest has several ways to handle this.Javascript에서 비동기 실행 코드는 일반적이다. 비..
원문: https://jestjs.io/docs/en/setup-teardown버전: Jest 23.6번역일: 2018-11-08※ 내용숙지 완벽하지 않은 번역이라, 원문을 함께 둠Setup and TeardownOften while writing tests you have some setup work that needs to happen before tests run, and you have some finishing work that needs to happen after tests run. Jest provides helper functions to handle this.종종 테스트를 작성할때 테스트가 실행되기전 설정 작업이 필요하면, 테스트가 실행되고 나서 설정 작업이 필요하다. Jest는 이런 ..
원문: https://jestjs.io/docs/en/using-matchers버전: Jest 23.6날짜: 2018-11-06※ 내용숙지가 안된 번역이 많아, 원문을 함께 둠Using MatchersJest uses "matchers" to let you test values in different ways. This document will introduce some commonly used matchers. For the full list, see the expect API doc.Jest는 여러가지 방법으로 값을 테스트할 수 있게 "matchers"를 사용한다. 이 문서는 일반적인 matchers를 사용법을 소개 할 것이다. 전체 목록은 expect API doc를 참조 하세요.Common Mat..
오랜만에 소식 전합니다^^, 저희는 여행의 반환점에(모로코) 거의 다 왔어요.여기는 포르투갈 '코임브라' 입니다. 포르투갈에는 남쪽 수도 '리스본', 그리고 북쪽에 큰 도시 '포르투'가 있는데그 사이에 있는 좀 작지만 유서 있는 도시 '코임브라'에 왔어요.코임브라는 옛 포르투갈의 수도로 역사도 깊고 특히 코임브라 대학이 유명 합니다.우리나라 조선시대쯤 세워진 대학이라는데 보존도 잘 되어있고(그 시대에 이런 건물이며, 대학이라니~), 대학교 도서관 내부가 정말 좋다고 하네요(아직 못가봄) 도시 이곳 저곳 둘러보며 아침 산책도 하고, 카페에 들어가 만들려고 하는 앱도 차근차근 구현하고, 익혀야 할 기술도 차근차근 배우고 있습니다.전 여유롭게 잘~~ 보내고 있어요^^ 돌아가서 이렇게 여유도 부리고 돈도 벌면서..
원문: https://jestjs.io/docs/en/mock-functions버전: Jest 23.6날짜: 2018-11-06※ 내용숙지가 안된 번역이 많아, 원문을 함께 둠Mock FunctionsMock functions make it easy to test the links between code by erasing the actual implementation of a function, capturing calls to the function (and the parameters passed in those calls), capturing instances of constructor functions when instantiated with new, and allowing test-time con..
원문: https://jestjs.io/docs/en/tutorial-async버전: Jest 23.6날짜: 2018-11-03※ 내용숙지가 안된 번역이 많아, 원문을 함께 둠An Async ExampleFirst, enable Babel support in Jest as documented in the Getting Started guide.Let's implement a simple module that fetches user data from an API and returns the user name.우선, Getting Started 가이드에서 설명된 데로 Jest에서 Babel 적용을 활성화 하자.API로 부터 user 데이터를 패치하고 user name을 반환하는 간단한 모듈을 구현하자.// ..
원문: https://jestjs.io/docs/en/tutorial-react-native버전: Jest 23.6날짜: 2018-11-01※ 내용숙지가 안된 번역이 많아, 원문을 함께 둠 Testing React Native AppsAt Facebook, we use Jest to test React Native applications.Get a deeper insight into testing a working React Native app example by reading the following series: Part 1: Jest – Snapshot come into play and Part 2: Jest – Redux Snapshots for your Actions and Reducers.페이..