added tests for staticqueue clear
Repaired a large number of tests case following the layer interface changes