File tree Expand file tree Collapse file tree 1 file changed +18
-18
lines changed Expand file tree Collapse file tree 1 file changed +18
-18
lines changed Original file line number Diff line number Diff line change @@ -105,7 +105,7 @@ async def test_reactive_value_unset():
105105
106106    val : int  =  0 
107107
108-     @effect () 
108+     @Effect () 
109109    def  o ():
110110        nonlocal  val 
111111        val  =  v ()
@@ -133,7 +133,7 @@ def o():
133133    v  =  Value [int ](MISSING )
134134    val2 : Union [bool , None ] =  None 
135135
136-     @effect () 
136+     @Effect () 
137137    def  o2 ():
138138        nonlocal  val2 
139139        val2  =  v .is_set ()
@@ -1002,22 +1002,16 @@ async def _():
10021002
10031003
10041004# ------------------------------------------------------------ 
1005- # @event() handles silent exceptions in event function, async  
1005+ # @event() handles silent exceptions in event function 
10061006# ------------------------------------------------------------ 
10071007@pytest .mark .asyncio  
1008- async  def  test_event_silent_exception_async ():
1008+ async  def  test_event_silent_exception ():
10091009    n_times  =  0 
10101010    x  =  Value [bool ]()
10111011
1012-     async  def  req_fn () ->  int :
1013-         await  asyncio .sleep (0 )
1014-         x ()
1015-         return  1234 
1016- 
1017-     @effect () 
1018-     @event (req_fn ) 
1019-     async  def  _ ():
1020-         await  asyncio .sleep (0 )
1012+     @Effect () 
1013+     @event (x ) 
1014+     def  _ ():
10211015        nonlocal  n_times 
10221016        n_times  +=  1 
10231017
@@ -1038,16 +1032,22 @@ async def _():
10381032
10391033
10401034# ------------------------------------------------------------ 
1041- # @event() handles silent exceptions in async  event function 
1035+ # @event() handles silent exceptions in event function, async  
10421036# ------------------------------------------------------------ 
10431037@pytest .mark .asyncio  
1044- async  def  test_event_silent_exception ():
1038+ async  def  test_event_silent_exception_async ():
10451039    n_times  =  0 
10461040    x  =  Value [bool ]()
10471041
1048-     @effect () 
1049-     @event (x ) 
1050-     def  _ ():
1042+     async  def  req_fn () ->  int :
1043+         await  asyncio .sleep (0 )
1044+         x ()
1045+         return  1234 
1046+ 
1047+     @Effect () 
1048+     @event (req_fn ) 
1049+     async  def  _ ():
1050+         await  asyncio .sleep (0 )
10511051        nonlocal  n_times 
10521052        n_times  +=  1 
10531053
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments