Make `SharedObject.defaultObjectEncoding` setter static

The getter already was, so this is essentially a typo. Fixes the SharedObject trace test.
Move SharedObject test from trace tests to ref tests because it relies on the DOM sessionStorage object.