forked from yuxh/gearman-go
		
	Tall server 'reset it' and clean the map.
This commit is contained in:
		
							parent
							
								
									b4a6f133e1
								
							
						
					
					
						commit
						da43d2efe5
					
				| @ -4,7 +4,7 @@ import ( | ||||
|     "os" | ||||
|     "net" | ||||
|     "sync" | ||||
|     "log" | ||||
| //    "log"
 | ||||
|     "strconv" | ||||
| ) | ||||
| 
 | ||||
|  | ||||
| @ -25,7 +25,7 @@ func TestClientEcho(t * testing.T) { | ||||
|         t.Log(echo) | ||||
|     } | ||||
| } | ||||
| /* | ||||
| 
 | ||||
| func TestClientDo(t * testing.T) { | ||||
|     if handle, err := client.Do("ToUpper", []byte("abcdef"), JOB_LOW | JOB_BG); err != nil { | ||||
|         t.Error(err) | ||||
| @ -33,17 +33,6 @@ func TestClientDo(t * testing.T) { | ||||
|         t.Log(handle) | ||||
|     } | ||||
| } | ||||
| */ | ||||
| /* | ||||
| func TestClientLastResult(t * testing.T) { | ||||
|     job := client.LastResult() | ||||
|     if job == nil { | ||||
|         t.Error(os.NewError("job shuold be the echo.")) | ||||
|     } else { | ||||
|         t.Log(job) | ||||
|     } | ||||
| } | ||||
| */ | ||||
| 
 | ||||
| func TestClientClose(t * testing.T) { | ||||
|     if err := client.Close(); err != nil { | ||||
|  | ||||
| @ -171,7 +171,9 @@ func (worker * Worker) Echo(data []byte) (err os.Error) { | ||||
| // Reset
 | ||||
| func (worker * Worker) Reset() (err os.Error){ | ||||
|     job := NewWorkerJob(REQ, RESET_ABILITIES, nil) | ||||
|     return worker.WriteJob(job) | ||||
|     err = worker.WriteJob(job) | ||||
|     worker.functions = make(JobFunctionMap) | ||||
|     return | ||||
| } | ||||
| 
 | ||||
| // SetId
 | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user