소스 검색

docs: fix false negative when checking `payload: false` in `testAction` (#1425)

Co-authored-by: Robert Schäfer <roschaefer@users.noreply.github.com>
Robert Schäfer 5 년 전
부모
커밋
7da1f139ba
1개의 변경된 파일1개의 추가작업 그리고 3개의 파일을 삭제
  1. 1 3
      docs/guide/testing.md

+ 1 - 3
docs/guide/testing.md

@@ -97,9 +97,7 @@ const testAction = (action, payload, state, expectedMutations, done) => {
 
     try {
       expect(type).to.equal(mutation.type)
-      if (payload) {
-        expect(payload).to.deep.equal(mutation.payload)
-      }
+      expect(payload).to.deep.equal(mutation.payload)
     } catch (error) {
       done(error)
     }