mono-tests: Fix after latest changes to eolian

Summary: Event payload checking is more strict now.

Test Plan: Check that master can be built

Reviewers: lauromoura, q66

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8437
This commit is contained in:
Xavi Artigas 2019-03-21 17:20:13 +01:00 committed by Daniel Kolesa
parent 5c1ea543bb
commit cbbc5e5eb6
3 changed files with 12 additions and 12 deletions

View File

@ -165,21 +165,21 @@ class TestEoEvents
Test.AssertEquals(sent_struct.Fobj, received_struct.Fobj); Test.AssertEquals(sent_struct.Fobj, received_struct.Fobj);
} }
public static void event_with_list_payload() public static void event_with_array_payload()
{ {
var obj = new Dummy.TestObject(); var obj = new Dummy.TestObject();
Eina.List<string> received = null; Eina.Array<string> received = null;
Eina.List<string> sent = new Eina.List<string>(); Eina.Array<string> sent = new Eina.Array<string>();
sent.Append("Abc"); sent.Append("Abc");
sent.Append("Def"); sent.Append("Def");
sent.Append("Ghi"); sent.Append("Ghi");
obj.EvtWithListEvt += (object sender, Dummy.TestObjectEvtWithListEvt_Args e) => { obj.EvtWithArrayEvt += (object sender, Dummy.TestObjectEvtWithArrayEvt_Args e) => {
received = e.arg; received = e.arg;
}; };
obj.EmitEventWithList(sent); obj.EmitEventWithArray(sent);
Test.AssertEquals(sent.Length, received.Length); Test.AssertEquals(sent.Length, received.Length);
var pairs = sent.Zip(received, (string sentItem, string receivedItem) => new { Sent = sentItem, Received = receivedItem } ); var pairs = sent.Zip(received, (string sentItem, string receivedItem) => new { Sent = sentItem, Received = receivedItem } );

View File

@ -1304,9 +1304,9 @@ class Dummy.Test_Object extends Efl.Object implements Dummy.Test_Iface {
} }
} }
emit_event_with_list { emit_event_with_array {
params { params {
@in data: list<string>; @in data: array<string>;
} }
} }
@ -1398,7 +1398,7 @@ class Dummy.Test_Object extends Efl.Object implements Dummy.Test_Iface {
Dummy.Test_Iface.iface_prop { get; set; } Dummy.Test_Iface.iface_prop { get; set; }
} }
events { events {
evt,with,string @hot: string; evt,with,string @hot: const(string);
evt,with,bool: bool; evt,with,bool: bool;
evt,with,int @hot: int; evt,with,int @hot: int;
evt,with,uint @hot: uint; evt,with,uint @hot: uint;
@ -1406,7 +1406,7 @@ class Dummy.Test_Object extends Efl.Object implements Dummy.Test_Iface {
evt,with,error @hot: Eina.Error; evt,with,error @hot: Eina.Error;
evt,with,struct @hot: Dummy.StructSimple; evt,with,struct @hot: Dummy.StructSimple;
evt,with,struct,complex @hot: Dummy.StructComplex; evt,with,struct,complex @hot: Dummy.StructComplex;
evt,with,list @hot: list<string>; evt,with,array @hot: const(array<string>);
evt_with,under @hot: void; evt_with,under @hot: void;
} }
} }

View File

@ -167,7 +167,7 @@ Efl_Object *_dummy_test_object_return_object(Eo *obj, EINA_UNUSED Dummy_Test_Obj
return obj; return obj;
} }
Efl_Object *_dummy_test_object_return_null_object(Eo *obj, EINA_UNUSED Dummy_Test_Object_Data *pd) Efl_Object *_dummy_test_object_return_null_object(Eo *obj EINA_UNUSED, EINA_UNUSED Dummy_Test_Object_Data *pd)
{ {
return NULL; return NULL;
} }
@ -3790,9 +3790,9 @@ void _dummy_test_object_emit_event_with_struct_complex(Eo *obj, EINA_UNUSED Dumm
efl_event_callback_legacy_call(obj, DUMMY_TEST_OBJECT_EVENT_EVT_WITH_STRUCT_COMPLEX, &data); efl_event_callback_legacy_call(obj, DUMMY_TEST_OBJECT_EVENT_EVT_WITH_STRUCT_COMPLEX, &data);
} }
void _dummy_test_object_emit_event_with_list(Eo *obj, EINA_UNUSED Dummy_Test_Object_Data *pd, Eina_List *data) void _dummy_test_object_emit_event_with_array(Eo *obj, EINA_UNUSED Dummy_Test_Object_Data *pd, Eina_Array *data)
{ {
efl_event_callback_legacy_call(obj, DUMMY_TEST_OBJECT_EVENT_EVT_WITH_LIST, data); efl_event_callback_legacy_call(obj, DUMMY_TEST_OBJECT_EVENT_EVT_WITH_ARRAY, data);
} }
void _dummy_test_object_emit_event_with_under(Eo *obj, EINA_UNUSED Dummy_Test_Object_Data *pd) void _dummy_test_object_emit_event_with_under(Eo *obj, EINA_UNUSED Dummy_Test_Object_Data *pd)