From 6df7df3343b8326b0fc05e74c56c706eed4d9f90 Mon Sep 17 00:00:00 2001 From: Mike Huang Date: Tue, 9 Jul 2024 21:36:30 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=8F=EF=B8=8F=20fix=20typo?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mastering-rxjs-35-how-to-test-rxjs-with-marble-diagrams.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/assets/blog/mastering-rxjs-35-how-to-test-rxjs-with-marble-diagrams.md b/src/assets/blog/mastering-rxjs-35-how-to-test-rxjs-with-marble-diagrams.md index ff8d844344..16ac9fdd9f 100644 --- a/src/assets/blog/mastering-rxjs-35-how-to-test-rxjs-with-marble-diagrams.md +++ b/src/assets/blog/mastering-rxjs-35-how-to-test-rxjs-with-marble-diagrams.md @@ -219,7 +219,7 @@ const testScheduler = new TestScheduler((actual, expected) => { 建立好 TestScheduler 後,我們需要呼叫該物件的 `run()` 方法,`run()` 方法內也是一個 callback function,在此 function 內會得到一個 `helper` 物件,這個物件可以幫助我們「以同步的方式測試非同步 Observable」,這個 helper 包含幾個方法: - `hot`:依照指定的彈珠圖建立一個 Hot Observable -- `cold`:依照指定的蛋ˋ豬屠建立一個 Cold Observable +- `cold`:依照指定的彈珠圖建立一個 Cold Observable - `expectObservable(...).toBe(...)`:用來判斷兩條 Observable 是否結果相同 - `expectSubscription(...).toBe(...)`:用來判斷「訂閱」和「結束訂閱」的結果是否符合預期 - `flush`:用來立即完成一個 Observable,通常用不到,只要在很細的控制測試需要