There are several places over the internet where you not only test your code but that can also serve as a small code repository to share with others
JsFiddle is a playground for web developers, a tool which may be used in many ways. Check my article Getting started with JS Fiddle
It’s worth checking, you can easily get code snippet of several google application code here
This tool will help you test your code with bunch of languages (over 40); you can also you your Facebook account to login and share code.
Quick and easy way to test your CSS.
Some what a short and easy version of jsfiddle
codepad is an online compiler/interpreter, and a simple collaboration tool.
Not that much worth, just include to keep track(might be they improve later)