From a5f962ab8eceee9b60034e2eca41b0c46befa754 Mon Sep 17 00:00:00 2001 From: Evan You Date: Sat, 9 Nov 2019 10:03:58 -0500 Subject: [PATCH] test(types): assert props are readonly --- test-dts/createComponent.test-d.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test-dts/createComponent.test-d.tsx b/test-dts/createComponent.test-d.tsx index 96a088b1..7d563207 100644 --- a/test-dts/createComponent.test-d.tsx +++ b/test-dts/createComponent.test-d.tsx @@ -50,6 +50,9 @@ describe('with object props', () => { expectType(props.ccc) expectType(props.ddd) + // props should be readonly + expectError((props.a = 1)) + // setup context return { c: ref(1),