def describe_file_systems(options={})
response = Excon::Response.new
file_systems = if id = options[:id]
if fs = self.data[:file_systems][id]
[fs]
else
raise Fog::AWS::EFS::NotFound.new("invalid file system ID: #{id}")
end
elsif creation_token = options[:creation_token]
fs = self.data[:file_systems].values.detect { |file_system| file_system["CreationToken"] == creation_token }
[fs]
else
self.data[:file_systems].values
end
file_systems.each do |file_system|
file_system['LifeCycleState'] = 'available'
self.data[:file_systems][file_system['FileSystemId']] = file_system
end
response.body = {"FileSystems" => file_systems}
response
end