Google and Time Warner's America Online unit have finalized an agreement by which the search giant will invest $1 billion for a 5 percent stake in AOL, according to documents filed with the U.S. Securities and Exchange Commission on Wednesday. The deal is expected to close before July. A Google representative could not provide details beyond what was in the regulatory filing. The companies announced the Google investment in December. The agreement expands their existing search engine relationship to include collaboration on advertising, instant messaging and video.