Переглянути джерело

reduce how many times the create and diff fuzzing runs

Evan Almloff 1 рік тому
батько
коміт
22f2c0ad9b
1 змінених файлів з 2 додано та 4 видалено
  1. 2 4
      packages/core/tests/fuzzing.rs

+ 2 - 4
packages/core/tests/fuzzing.rs

@@ -305,10 +305,9 @@ fn create_random_element(cx: Scope<DepthProps>) -> Element {
 }
 
 // test for panics when creating random nodes and templates
-#[cfg(not(miri))]
 #[test]
 fn create() {
-    for _ in 0..1000 {
+    for _ in 0..100 {
         let mut vdom =
             VirtualDom::new_with_props(create_random_element, DepthProps { depth: 0, root: true });
         let _ = vdom.rebuild();
@@ -317,10 +316,9 @@ fn create() {
 
 // test for panics when diffing random nodes
 // This test will change the template every render which is not very realistic, but it helps stress the system
-#[cfg(not(miri))]
 #[test]
 fn diff() {
-    for _ in 0..100000 {
+    for _ in 0..10 {
         let mut vdom =
             VirtualDom::new_with_props(create_random_element, DepthProps { depth: 0, root: true });
         let _ = vdom.rebuild();