/* avatar-details.c generated by valac 0.14.0.15-f8b5, the Vala compiler
 * generated from avatar-details.vala, do not modify */

/*
 * Copyright (C) 2011 Collabora Ltd.
 *
 * This library is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License as published by
 * the Free Software Foundation, either version 2.1 of the License, or
 * (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this library.  If not, see <http://www.gnu.org/licenses/>.
 *
 * Authors: Raul Gutierrez Segales <raul.gutierrez.segales@collabora.co.uk>
 *
 */

#include <glib.h>
#include <glib-object.h>
#include <folks-test.h>
#include <eds-test.h>
#include <folks/folks.h>
#include <gee.h>
#include <stdlib.h>
#include <string.h>
#include <gio/gio.h>


#define TYPE_AVATAR_DETAILS_TESTS (avatar_details_tests_get_type ())
#define AVATAR_DETAILS_TESTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_AVATAR_DETAILS_TESTS, AvatarDetailsTests))
#define AVATAR_DETAILS_TESTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_AVATAR_DETAILS_TESTS, AvatarDetailsTestsClass))
#define IS_AVATAR_DETAILS_TESTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_AVATAR_DETAILS_TESTS))
#define IS_AVATAR_DETAILS_TESTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_AVATAR_DETAILS_TESTS))
#define AVATAR_DETAILS_TESTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_AVATAR_DETAILS_TESTS, AvatarDetailsTestsClass))

typedef struct _AvatarDetailsTests AvatarDetailsTests;
typedef struct _AvatarDetailsTestsClass AvatarDetailsTestsClass;
typedef struct _AvatarDetailsTestsPrivate AvatarDetailsTestsPrivate;
#define _eds_test_backend_unref0(var) ((var == NULL) ? NULL : (var = (eds_test_backend_unref (var), NULL)))
#define _g_main_loop_unref0(var) ((var == NULL) ? NULL : (var = (g_main_loop_unref (var), NULL)))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))
#define __vala_GValue_free0(var) ((var == NULL) ? NULL : (var = (_vala_GValue_free (var), NULL)))
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
typedef struct _AvatarDetailsTestsTestAvatarAsyncData AvatarDetailsTestsTestAvatarAsyncData;
typedef struct _AvatarDetailsTestsCheckAvatarData AvatarDetailsTestsCheckAvatarData;

struct _AvatarDetailsTests {
	FolksTestCase parent_instance;
	AvatarDetailsTestsPrivate * priv;
};

struct _AvatarDetailsTestsClass {
	FolksTestCaseClass parent_class;
};

struct _AvatarDetailsTestsPrivate {
	EdsTestBackend* _eds_backend;
	GMainLoop* _main_loop;
	FolksIndividualAggregator* _aggregator;
	GeeHashMap* _c1;
	gboolean _avatars_are_equal;
	gchar* _avatar_path;
};

struct _AvatarDetailsTestsTestAvatarAsyncData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	AvatarDetailsTests* self;
	EdsTestBackend* _tmp0_;
	FolksBackendStore* _tmp1_;
	FolksBackendStore* store;
	FolksIndividualAggregator* _tmp2_;
	FolksIndividualAggregator* _tmp3_;
	FolksIndividualAggregator* _tmp4_;
	GError* e;
	GError* _tmp5_;
	const gchar* _tmp6_;
	GError * _inner_error_;
};

struct _AvatarDetailsTestsCheckAvatarData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	AvatarDetailsTests* self;
	GLoadableIcon* avatar;
	GLoadableIcon* _tmp0_;
	const gchar* _tmp1_;
	GFile* _tmp2_;
	GFile* _tmp3_;
	GFileIcon* _tmp4_;
	GFileIcon* _tmp5_;
	GFileIcon* b;
	GLoadableIcon* _tmp6_;
	GFileIcon* _tmp7_;
	gboolean _tmp8_;
	GMainLoop* _tmp9_;
};


static gpointer avatar_details_tests_parent_class = NULL;

GType avatar_details_tests_get_type (void) G_GNUC_CONST;
#define AVATAR_DETAILS_TESTS_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_AVATAR_DETAILS_TESTS, AvatarDetailsTestsPrivate))
enum  {
	AVATAR_DETAILS_TESTS_DUMMY_PROPERTY
};
AvatarDetailsTests* avatar_details_tests_new (void);
AvatarDetailsTests* avatar_details_tests_construct (GType object_type);
void avatar_details_tests_test_avatar (AvatarDetailsTests* self);
static void _avatar_details_tests_test_avatar_folks_test_case_test_method (gpointer self);
static void avatar_details_tests_real_set_up (FolksTestCase* base);
static void avatar_details_tests_real_tear_down (FolksTestCase* base);
static GValue* _g_value_dup (GValue* self);
static void _vala_GValue_free (GValue* self);
static void _avatar_details_tests_test_avatar_async (AvatarDetailsTests* self, GAsyncReadyCallback _callback_, gpointer _user_data_);
static void _avatar_details_tests_test_avatar_finish (AvatarDetailsTests* self, GAsyncResult* _res_);
static gboolean __lambda2_ (AvatarDetailsTests* self);
static gboolean ___lambda2__gsource_func (gpointer self);
static void _avatar_details_tests_test_avatar_async_data_free (gpointer _data);
static gboolean _avatar_details_tests_test_avatar_async_co (AvatarDetailsTestsTestAvatarAsyncData* _data_);
static void _avatar_details_tests_test_avatar_async_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void _avatar_details_tests_individuals_changed_cb (AvatarDetailsTests* self, GeeMultiMap* changes);
static void __avatar_details_tests_individuals_changed_cb_folks_individual_aggregator_individuals_changed_detailed (FolksIndividualAggregator* _sender, GeeMultiMap* changes, gpointer self);
static void _avatar_details_tests_notify_cb (AvatarDetailsTests* self, GObject* individual_obj, GParamSpec* ps);
static void __avatar_details_tests_notify_cb_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void _avatar_details_tests_check_avatar (AvatarDetailsTests* self, GLoadableIcon* avatar, GAsyncReadyCallback _callback_, gpointer _user_data_);
static void _avatar_details_tests_check_avatar_finish (AvatarDetailsTests* self, GAsyncResult* _res_);
static void _avatar_details_tests_check_avatar_data_free (gpointer _data);
static gboolean _avatar_details_tests_check_avatar_co (AvatarDetailsTestsCheckAvatarData* _data_);
static void _avatar_details_tests_check_avatar_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void avatar_details_tests_finalize (GObject* obj);
gint _vala_main (gchar** args, int args_length1);


static void _avatar_details_tests_test_avatar_folks_test_case_test_method (gpointer self) {
#line 40 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	avatar_details_tests_test_avatar (self);
#line 150 "avatar-details.c"
}


AvatarDetailsTests* avatar_details_tests_construct (GType object_type) {
	AvatarDetailsTests * self = NULL;
	EdsTestBackend* _tmp0_;
#line 36 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self = (AvatarDetailsTests*) folks_test_case_construct (object_type, "AvatarDetails");
#line 38 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = eds_test_backend_new ();
#line 38 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_eds_test_backend_unref0 (self->priv->_eds_backend);
#line 38 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self->priv->_eds_backend = _tmp0_;
#line 40 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	folks_test_case_add_test ((FolksTestCase*) self, "avatar details interface", _avatar_details_tests_test_avatar_folks_test_case_test_method, self);
#line 34 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return self;
#line 169 "avatar-details.c"
}


AvatarDetailsTests* avatar_details_tests_new (void) {
#line 34 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return avatar_details_tests_construct (TYPE_AVATAR_DETAILS_TESTS);
#line 176 "avatar-details.c"
}


static void avatar_details_tests_real_set_up (FolksTestCase* base) {
	AvatarDetailsTests * self;
	EdsTestBackend* _tmp0_;
#line 43 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self = (AvatarDetailsTests*) base;
#line 45 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = self->priv->_eds_backend;
#line 45 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	eds_test_backend_set_up (_tmp0_, FALSE);
#line 189 "avatar-details.c"
}


static void avatar_details_tests_real_tear_down (FolksTestCase* base) {
	AvatarDetailsTests * self;
	EdsTestBackend* _tmp0_;
#line 48 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self = (AvatarDetailsTests*) base;
#line 50 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = self->priv->_eds_backend;
#line 50 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	eds_test_backend_tear_down (_tmp0_);
#line 202 "avatar-details.c"
}


static GValue* _g_value_dup (GValue* self) {
#line 55 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return g_boxed_copy (G_TYPE_VALUE, self);
#line 209 "avatar-details.c"
}


static void _vala_GValue_free (GValue* self) {
#line 55 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_value_unset (self);
#line 55 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_free (self);
#line 218 "avatar-details.c"
}


static gpointer __g_value_dup0 (gpointer self) {
#line 63 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return self ? _g_value_dup (self) : NULL;
#line 225 "avatar-details.c"
}


static gpointer _g_object_ref0 (gpointer self) {
#line 69 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return self ? g_object_ref (self) : NULL;
#line 232 "avatar-details.c"
}


static gboolean __lambda2_ (AvatarDetailsTests* self) {
	gboolean result = FALSE;
	GMainLoop* _tmp0_;
#line 75 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = self->priv->_main_loop;
#line 75 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_main_loop_quit (_tmp0_);
#line 76 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	result = FALSE;
#line 76 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return result;
#line 247 "avatar-details.c"
}


static gboolean ___lambda2__gsource_func (gpointer self) {
	gboolean result;
	result = __lambda2_ (self);
#line 73 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return result;
#line 256 "avatar-details.c"
}


void avatar_details_tests_test_avatar (AvatarDetailsTests* self) {
	GeeHashMap* _tmp0_;
	GMainLoop* _tmp1_;
	const gchar* _tmp2_ = NULL;
	gchar* _tmp3_;
	GValue* v = NULL;
	EdsTestBackend* _tmp4_;
	GValue _tmp5_ = {0};
	GValue _tmp6_;
	GValue* _tmp7_;
	GValue* _tmp8_;
	GeeHashMap* _tmp9_;
	GValue* _tmp10_;
	GValue* _tmp11_;
	GValue _tmp12_ = {0};
	GValue _tmp13_;
	GValue* _tmp14_;
	GValue* _tmp15_;
	const gchar* _tmp16_;
	GeeHashMap* _tmp17_;
	GValue* _tmp18_;
	GValue* _tmp19_;
	EdsTestBackend* _tmp20_;
	GeeHashMap* _tmp21_;
	GeeHashMap* _tmp22_;
	GMainLoop* _tmp23_;
	gboolean _tmp24_;
#line 53 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_return_if_fail (self != NULL);
#line 55 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, G_TYPE_VALUE, (GBoxedCopyFunc) _g_value_dup, _vala_GValue_free, NULL, NULL, NULL);
#line 55 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (self->priv->_c1);
#line 55 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self->priv->_c1 = _tmp0_;
#line 56 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp1_ = g_main_loop_new (NULL, FALSE);
#line 56 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_main_loop_unref0 (self->priv->_main_loop);
#line 56 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self->priv->_main_loop = _tmp1_;
#line 57 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp2_ = g_getenv ("AVATAR_FILE_PATH");
#line 57 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp3_ = g_strdup (_tmp2_);
#line 57 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_free0 (self->priv->_avatar_path);
#line 57 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self->priv->_avatar_path = _tmp3_;
#line 58 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self->priv->_avatars_are_equal = FALSE;
#line 61 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp4_ = self->priv->_eds_backend;
#line 61 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	eds_test_backend_reset (_tmp4_);
#line 63 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_value_init (&_tmp5_, G_TYPE_STRING);
#line 63 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp6_ = _tmp5_;
#line 63 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp7_ = __g_value_dup0 (&_tmp6_);
#line 63 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	__vala_GValue_free0 (v);
#line 63 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	v = _tmp7_;
#line 63 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	G_IS_VALUE (&_tmp6_) ? (g_value_unset (&_tmp6_), NULL) : NULL;
#line 64 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp8_ = v;
#line 64 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_value_set_string (_tmp8_, "bernie h. innocenti");
#line 65 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp9_ = self->priv->_c1;
#line 65 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp10_ = v;
#line 65 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	v = NULL;
#line 65 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp11_ = _tmp10_;
#line 65 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	gee_abstract_map_set ((GeeAbstractMap*) _tmp9_, "full_name", _tmp11_);
#line 65 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	__vala_GValue_free0 (_tmp11_);
#line 66 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_value_init (&_tmp12_, G_TYPE_STRING);
#line 66 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp13_ = _tmp12_;
#line 66 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp14_ = __g_value_dup0 (&_tmp13_);
#line 66 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	__vala_GValue_free0 (v);
#line 66 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	v = _tmp14_;
#line 66 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	G_IS_VALUE (&_tmp13_) ? (g_value_unset (&_tmp13_), NULL) : NULL;
#line 67 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp15_ = v;
#line 67 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp16_ = self->priv->_avatar_path;
#line 67 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_value_set_string (_tmp15_, _tmp16_);
#line 68 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp17_ = self->priv->_c1;
#line 68 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp18_ = v;
#line 68 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	v = NULL;
#line 68 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp19_ = _tmp18_;
#line 68 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	gee_abstract_map_set ((GeeAbstractMap*) _tmp17_, "avatar", _tmp19_);
#line 68 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	__vala_GValue_free0 (_tmp19_);
#line 69 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp20_ = self->priv->_eds_backend;
#line 69 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp21_ = self->priv->_c1;
#line 69 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp22_ = _g_object_ref0 (_tmp21_);
#line 69 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	eds_test_backend_add_contact (_tmp20_, _tmp22_);
#line 71 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_avatar_details_tests_test_avatar_async (self, NULL, NULL);
#line 73 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_timeout_add_seconds_full (G_PRIORITY_DEFAULT, (guint) 5, ___lambda2__gsource_func, g_object_ref (self), g_object_unref);
#line 79 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp23_ = self->priv->_main_loop;
#line 79 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_main_loop_run (_tmp23_);
#line 81 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp24_ = self->priv->_avatars_are_equal;
#line 81 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_assert (_tmp24_);
#line 53 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	__vala_GValue_free0 (v);
#line 395 "avatar-details.c"
}


static void _avatar_details_tests_test_avatar_async_data_free (gpointer _data) {
	AvatarDetailsTestsTestAvatarAsyncData* _data_;
	_data_ = _data;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (_data_->self);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_slice_free (AvatarDetailsTestsTestAvatarAsyncData, _data_);
#line 406 "avatar-details.c"
}


static void _avatar_details_tests_test_avatar_async (AvatarDetailsTests* self, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	AvatarDetailsTestsTestAvatarAsyncData* _data_;
	AvatarDetailsTests* _tmp0_;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_ = g_slice_new0 (AvatarDetailsTestsTestAvatarAsyncData);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, _avatar_details_tests_test_avatar_async);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, _avatar_details_tests_test_avatar_async_data_free);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = _g_object_ref0 (self);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->self = _tmp0_;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_avatar_details_tests_test_avatar_async_co (_data_);
#line 425 "avatar-details.c"
}


static void _avatar_details_tests_test_avatar_finish (AvatarDetailsTests* self, GAsyncResult* _res_) {
	AvatarDetailsTestsTestAvatarAsyncData* _data_;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
#line 433 "avatar-details.c"
}


static void _avatar_details_tests_test_avatar_async_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	AvatarDetailsTestsTestAvatarAsyncData* _data_;
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_ = _user_data_;
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_source_object_ = source_object;
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_res_ = _res_;
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_avatar_details_tests_test_avatar_async_co (_data_);
#line 447 "avatar-details.c"
}


static void __avatar_details_tests_individuals_changed_cb_folks_individual_aggregator_individuals_changed_detailed (FolksIndividualAggregator* _sender, GeeMultiMap* changes, gpointer self) {
#line 92 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_avatar_details_tests_individuals_changed_cb (self, changes);
#line 454 "avatar-details.c"
}


static gboolean _avatar_details_tests_test_avatar_async_co (AvatarDetailsTestsTestAvatarAsyncData* _data_) {
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	switch (_data_->_state_) {
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		case 0:
#line 463 "avatar-details.c"
		goto _state_0;
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		case 1:
#line 467 "avatar-details.c"
		goto _state_1;
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		case 2:
#line 471 "avatar-details.c"
		goto _state_2;
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		case 3:
#line 475 "avatar-details.c"
		goto _state_3;
		default:
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_assert_not_reached ();
#line 480 "avatar-details.c"
	}
	_state_0:
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_tmp0_ = _data_->self->priv->_eds_backend;
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_state_ = 1;
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	eds_test_backend_commit_contacts_to_addressbook (_data_->_tmp0_, _avatar_details_tests_test_avatar_async_ready, _data_);
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return FALSE;
#line 491 "avatar-details.c"
	_state_1:
#line 87 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	eds_test_backend_commit_contacts_to_addressbook_finish (_data_->_tmp0_, _data_->_res_);
#line 89 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_tmp1_ = NULL;
#line 89 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_tmp1_ = folks_backend_store_dup ();
#line 89 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->store = _data_->_tmp1_;
#line 90 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_state_ = 2;
#line 90 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	folks_backend_store_prepare (_data_->store, _avatar_details_tests_test_avatar_async_ready, _data_);
#line 90 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return FALSE;
#line 507 "avatar-details.c"
	_state_2:
#line 90 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	folks_backend_store_prepare_finish (_data_->store, _data_->_res_);
#line 91 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_tmp2_ = folks_individual_aggregator_new ();
#line 91 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (_data_->self->priv->_aggregator);
#line 91 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->self->priv->_aggregator = _data_->_tmp2_;
#line 92 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_tmp3_ = _data_->self->priv->_aggregator;
#line 92 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_signal_connect_object (_data_->_tmp3_, "individuals-changed-detailed", (GCallback) __avatar_details_tests_individuals_changed_cb_folks_individual_aggregator_individuals_changed_detailed, _data_->self, 0);
#line 521 "avatar-details.c"
	{
#line 96 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp4_ = _data_->self->priv->_aggregator;
#line 96 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_state_ = 3;
#line 96 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		folks_individual_aggregator_prepare (_data_->_tmp4_, _avatar_details_tests_test_avatar_async_ready, _data_);
#line 96 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		return FALSE;
#line 531 "avatar-details.c"
		_state_3:
#line 96 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		folks_individual_aggregator_prepare_finish (_data_->_tmp4_, _data_->_res_, &_data_->_inner_error_);
#line 96 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		if (_data_->_inner_error_ != NULL) {
#line 537 "avatar-details.c"
			goto __catch0_g_error;
		}
	}
	goto __finally0;
	__catch0_g_error:
	{
#line 94 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->e = _data_->_inner_error_;
#line 94 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_inner_error_ = NULL;
#line 100 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp5_ = _data_->e;
#line 100 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp6_ = _data_->_tmp5_->message;
#line 100 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_warning ("avatar-details.vala:100: Error when calling prepare: %s\n", _data_->_tmp6_);
#line 94 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_g_error_free0 (_data_->e);
#line 556 "avatar-details.c"
	}
	__finally0:
#line 94 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	if (_data_->_inner_error_ != NULL) {
#line 94 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_g_object_unref0 (_data_->store);
#line 94 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error_->message, g_quark_to_string (_data_->_inner_error_->domain), _data_->_inner_error_->code);
#line 94 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_clear_error (&_data_->_inner_error_);
#line 94 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		return FALSE;
#line 569 "avatar-details.c"
	}
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (_data_->store);
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	if (_data_->_state_ == 0) {
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 577 "avatar-details.c"
	} else {
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_simple_async_result_complete (_data_->_async_result);
#line 581 "avatar-details.c"
	}
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_object_unref (_data_->_async_result);
#line 84 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return FALSE;
#line 587 "avatar-details.c"
}


static void __avatar_details_tests_notify_cb_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 125 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_avatar_details_tests_notify_cb (self, _sender, pspec);
#line 594 "avatar-details.c"
}


static void _avatar_details_tests_individuals_changed_cb (AvatarDetailsTests* self, GeeMultiMap* changes) {
	GeeMultiMap* _tmp0_;
	GeeCollection* _tmp1_ = NULL;
	GeeCollection* added;
	GeeMultiMap* _tmp2_;
	GeeSet* _tmp3_ = NULL;
	GeeSet* removed;
	GeeSet* _tmp4_;
	gint _tmp5_;
	gint _tmp6_;
#line 104 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_return_if_fail (self != NULL);
#line 104 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_return_if_fail (changes != NULL);
#line 107 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = changes;
#line 107 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp1_ = gee_multi_map_get_values (_tmp0_);
#line 107 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	added = _tmp1_;
#line 108 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp2_ = changes;
#line 108 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp3_ = gee_multi_map_get_keys (_tmp2_);
#line 108 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	removed = _tmp3_;
#line 110 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp4_ = removed;
#line 110 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp5_ = gee_collection_get_size ((GeeCollection*) _tmp4_);
#line 110 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp6_ = _tmp5_;
#line 110 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_assert (_tmp6_ == 1);
#line 632 "avatar-details.c"
	{
		GeeSet* _tmp7_;
		GeeIterator* _tmp8_ = NULL;
		GeeIterator* _i_it;
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_tmp7_ = removed;
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_tmp8_ = gee_iterable_iterator ((GeeIterable*) _tmp7_);
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_i_it = _tmp8_;
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		while (TRUE) {
#line 645 "avatar-details.c"
			GeeIterator* _tmp9_;
			gboolean _tmp10_ = FALSE;
			GeeIterator* _tmp11_;
			gpointer _tmp12_ = NULL;
			FolksIndividual* i;
			FolksIndividual* _tmp13_;
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp9_ = _i_it;
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp10_ = gee_iterator_next (_tmp9_);
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			if (!_tmp10_) {
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
				break;
#line 660 "avatar-details.c"
			}
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp11_ = _i_it;
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp12_ = gee_iterator_get (_tmp11_);
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			i = (FolksIndividual*) _tmp12_;
#line 114 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp13_ = i;
#line 114 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			g_assert (_tmp13_ == NULL);
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_g_object_unref0 (i);
#line 674 "avatar-details.c"
		}
#line 112 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_g_object_unref0 (_i_it);
#line 678 "avatar-details.c"
	}
	{
		GeeCollection* _tmp14_;
		GeeIterator* _tmp15_ = NULL;
		GeeIterator* _i_it;
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_tmp14_ = added;
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_tmp15_ = gee_iterable_iterator ((GeeIterable*) _tmp14_);
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_i_it = _tmp15_;
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		while (TRUE) {
#line 692 "avatar-details.c"
			GeeIterator* _tmp16_;
			gboolean _tmp17_ = FALSE;
			GeeIterator* _tmp18_;
			gpointer _tmp19_ = NULL;
			FolksIndividual* i;
			FolksIndividual* _tmp20_;
			FolksIndividual* _tmp21_;
			GeeSet* _tmp22_;
			GeeSet* _tmp23_;
			gint _tmp24_;
			gint _tmp25_;
			FolksIndividual* _tmp26_;
			const gchar* _tmp27_;
			const gchar* _tmp28_;
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp16_ = _i_it;
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp17_ = gee_iterator_next (_tmp16_);
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			if (!_tmp17_) {
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
				break;
#line 715 "avatar-details.c"
			}
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp18_ = _i_it;
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp19_ = gee_iterator_get (_tmp18_);
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			i = (FolksIndividual*) _tmp19_;
#line 119 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp20_ = i;
#line 119 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			g_assert (_tmp20_ != NULL);
#line 121 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp21_ = i;
#line 121 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp22_ = folks_individual_get_personas (_tmp21_);
#line 121 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp23_ = _tmp22_;
#line 121 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp24_ = gee_collection_get_size ((GeeCollection*) _tmp23_);
#line 121 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp25_ = _tmp24_;
#line 121 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			g_assert (_tmp25_ == 1);
#line 123 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp26_ = i;
#line 123 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp27_ = folks_name_details_get_full_name ((FolksNameDetails*) _tmp26_);
#line 123 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_tmp28_ = _tmp27_;
#line 123 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			if (g_strcmp0 (_tmp28_, "bernie h. innocenti") == 0) {
#line 747 "avatar-details.c"
				FolksIndividual* _tmp29_;
				FolksIndividual* _tmp30_;
				GLoadableIcon* _tmp31_;
				GLoadableIcon* _tmp32_;
#line 125 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
				_tmp29_ = i;
#line 125 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
				g_signal_connect_object ((GObject*) _tmp29_, "notify::avatar", (GCallback) __avatar_details_tests_notify_cb_g_object_notify, self, 0);
#line 126 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
				_tmp30_ = i;
#line 126 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
				_tmp31_ = folks_avatar_details_get_avatar ((FolksAvatarDetails*) _tmp30_);
#line 126 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
				_tmp32_ = _tmp31_;
#line 126 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
				_avatar_details_tests_check_avatar (self, _tmp32_, NULL, NULL);
#line 764 "avatar-details.c"
			}
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
			_g_object_unref0 (i);
#line 768 "avatar-details.c"
		}
#line 117 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_g_object_unref0 (_i_it);
#line 772 "avatar-details.c"
	}
#line 104 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (removed);
#line 104 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (added);
#line 778 "avatar-details.c"
}


static void _avatar_details_tests_notify_cb (AvatarDetailsTests* self, GObject* individual_obj, GParamSpec* ps) {
	GObject* _tmp0_;
	FolksIndividual* _tmp1_;
	FolksIndividual* i;
	GLoadableIcon* _tmp2_;
	GLoadableIcon* _tmp3_;
#line 131 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_return_if_fail (self != NULL);
#line 131 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_return_if_fail (individual_obj != NULL);
#line 131 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_return_if_fail (ps != NULL);
#line 133 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = individual_obj;
#line 133 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp1_ = _g_object_ref0 (FOLKS_INDIVIDUAL (_tmp0_));
#line 133 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	i = _tmp1_;
#line 134 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp2_ = folks_avatar_details_get_avatar ((FolksAvatarDetails*) i);
#line 134 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp3_ = _tmp2_;
#line 134 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_avatar_details_tests_check_avatar (self, _tmp3_, NULL, NULL);
#line 131 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (i);
#line 808 "avatar-details.c"
}


static void _avatar_details_tests_check_avatar_data_free (gpointer _data) {
	AvatarDetailsTestsCheckAvatarData* _data_;
	_data_ = _data;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (_data_->avatar);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (_data_->self);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_slice_free (AvatarDetailsTestsCheckAvatarData, _data_);
#line 821 "avatar-details.c"
}


static void _avatar_details_tests_check_avatar (AvatarDetailsTests* self, GLoadableIcon* avatar, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	AvatarDetailsTestsCheckAvatarData* _data_;
	AvatarDetailsTests* _tmp0_;
	GLoadableIcon* _tmp1_;
	GLoadableIcon* _tmp2_;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_ = g_slice_new0 (AvatarDetailsTestsCheckAvatarData);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, _avatar_details_tests_check_avatar);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, _avatar_details_tests_check_avatar_data_free);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = _g_object_ref0 (self);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->self = _tmp0_;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp1_ = avatar;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp2_ = _g_object_ref0 (_tmp1_);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->avatar = _tmp2_;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_avatar_details_tests_check_avatar_co (_data_);
#line 848 "avatar-details.c"
}


static void _avatar_details_tests_check_avatar_finish (AvatarDetailsTests* self, GAsyncResult* _res_) {
	AvatarDetailsTestsCheckAvatarData* _data_;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
#line 856 "avatar-details.c"
}


static void _avatar_details_tests_check_avatar_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	AvatarDetailsTestsCheckAvatarData* _data_;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_ = _user_data_;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_source_object_ = source_object;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_res_ = _res_;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_avatar_details_tests_check_avatar_co (_data_);
#line 870 "avatar-details.c"
}


static gboolean _avatar_details_tests_check_avatar_co (AvatarDetailsTestsCheckAvatarData* _data_) {
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	switch (_data_->_state_) {
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		case 0:
#line 879 "avatar-details.c"
		goto _state_0;
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		case 1:
#line 883 "avatar-details.c"
		goto _state_1;
		default:
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_assert_not_reached ();
#line 888 "avatar-details.c"
	}
	_state_0:
#line 139 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_data_->_tmp0_ = _data_->avatar;
#line 139 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	if (_data_->_tmp0_ != NULL) {
#line 141 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp1_ = _data_->self->priv->_avatar_path;
#line 141 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp2_ = NULL;
#line 141 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp2_ = g_file_new_for_path (_data_->_tmp1_);
#line 141 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp3_ = _data_->_tmp2_;
#line 141 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp4_ = (GFileIcon*) g_file_icon_new (_data_->_tmp3_);
#line 141 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp5_ = _data_->_tmp4_;
#line 141 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_g_object_unref0 (_data_->_tmp3_);
#line 141 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->b = _data_->_tmp5_;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp6_ = _data_->avatar;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp7_ = _data_->b;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_state_ = 1;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		folks_test_utils_loadable_icons_content_equal (_data_->_tmp6_, (GLoadableIcon*) _data_->_tmp7_, -1, _avatar_details_tests_check_avatar_ready, _data_);
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		return FALSE;
#line 921 "avatar-details.c"
		_state_1:
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp8_ = FALSE;
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp8_ = folks_test_utils_loadable_icons_content_equal_finish (_data_->_res_);
#line 143 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->self->priv->_avatars_are_equal = _data_->_tmp8_;
#line 146 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_data_->_tmp9_ = _data_->self->priv->_main_loop;
#line 146 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_main_loop_quit (_data_->_tmp9_);
#line 139 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		_g_object_unref0 (_data_->b);
#line 935 "avatar-details.c"
	}
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	if (_data_->_state_ == 0) {
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 941 "avatar-details.c"
	} else {
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
		g_simple_async_result_complete (_data_->_async_result);
#line 945 "avatar-details.c"
	}
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_object_unref (_data_->_async_result);
#line 137 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return FALSE;
#line 951 "avatar-details.c"
}


static void avatar_details_tests_class_init (AvatarDetailsTestsClass * klass) {
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	avatar_details_tests_parent_class = g_type_class_peek_parent (klass);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_type_class_add_private (klass, sizeof (AvatarDetailsTestsPrivate));
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	FOLKS_TEST_CASE_CLASS (klass)->set_up = avatar_details_tests_real_set_up;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	FOLKS_TEST_CASE_CLASS (klass)->tear_down = avatar_details_tests_real_tear_down;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	G_OBJECT_CLASS (klass)->finalize = avatar_details_tests_finalize;
#line 966 "avatar-details.c"
}


static void avatar_details_tests_instance_init (AvatarDetailsTests * self) {
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self->priv = AVATAR_DETAILS_TESTS_GET_PRIVATE (self);
#line 973 "avatar-details.c"
}


static void avatar_details_tests_finalize (GObject* obj) {
	AvatarDetailsTests * self;
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	self = AVATAR_DETAILS_TESTS (obj);
#line 27 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_eds_test_backend_unref0 (self->priv->_eds_backend);
#line 28 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_main_loop_unref0 (self->priv->_main_loop);
#line 29 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (self->priv->_aggregator);
#line 30 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (self->priv->_c1);
#line 32 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_free0 (self->priv->_avatar_path);
#line 25 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	G_OBJECT_CLASS (avatar_details_tests_parent_class)->finalize (obj);
#line 993 "avatar-details.c"
}


GType avatar_details_tests_get_type (void) {
	static volatile gsize avatar_details_tests_type_id__volatile = 0;
	if (g_once_init_enter (&avatar_details_tests_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (AvatarDetailsTestsClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) avatar_details_tests_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (AvatarDetailsTests), 0, (GInstanceInitFunc) avatar_details_tests_instance_init, NULL };
		GType avatar_details_tests_type_id;
		avatar_details_tests_type_id = g_type_register_static (FOLKS_TYPE_TEST_CASE, "AvatarDetailsTests", &g_define_type_info, 0);
		g_once_init_leave (&avatar_details_tests_type_id__volatile, avatar_details_tests_type_id);
	}
	return avatar_details_tests_type_id__volatile;
}


gint _vala_main (gchar** args, int args_length1) {
	gint result = 0;
	GTestSuite* _tmp0_ = NULL;
	GTestSuite* root;
	AvatarDetailsTests* _tmp1_;
	AvatarDetailsTests* _tmp2_;
	GTestSuite* _tmp3_ = NULL;
#line 153 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_test_init (&args_length1, &args, NULL);
#line 155 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp0_ = g_test_get_root ();
#line 155 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	root = _tmp0_;
#line 156 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp1_ = avatar_details_tests_new ();
#line 156 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp2_ = _tmp1_;
#line 156 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_tmp3_ = folks_test_case_get_suite ((FolksTestCase*) _tmp2_);
#line 156 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_test_suite_add_suite (root, _tmp3_);
#line 156 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	_g_object_unref0 (_tmp2_);
#line 158 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_test_run ();
#line 160 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	result = 0;
#line 160 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return result;
#line 1038 "avatar-details.c"
}


int main (int argc, char ** argv) {
#line 151 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	g_type_init ();
#line 151 "/home/treitter/collabora/folks/tests/eds/avatar-details.vala"
	return _vala_main (argv, argc);
#line 1047 "avatar-details.c"
}



