Added serialization and test for FileSystem.