code: func (ec2i *FakeEC2Impl) DescribeInstances(request *ec2.DescribeInstancesInput) ([]*ec2.Instance, error) {
  	matches := []*ec2.Instance{}
  	for _, instance := range ec2i.aws.instances {
  		if request.InstanceIds != nil {
  			if instance.InstanceId == nil {
  				klog.Warning("Instance with no instance id: ", instance)
  				continue
  			}
  
  			found := false
  			for _, instanceID := range request.InstanceIds {
  				if *instanceID == *instance.InstanceId {
  					found = true
  					break
  				}
  			}
  			if !found {
  				continue
  			}
  		}
  		if request.Filters != nil {
  			allMatch := true
  			for _, filter := range request.Filters {
  				if !instanceMatchesFilter(instance, filter) {
  					allMatch = false
  					break
  				}
  			}
  			if !allMatch {
  				continue
  			}
  		}
  		matches = append(matches, instance)
  	}
  
  	return matches, nil
  }
docs: // DescribeInstances returns fake instance descriptions