forked from enlightenment/efl
csharp: Add test for static interface members
For the checks added in D9893
This commit is contained in:
parent
4bacfe155f
commit
09c3517d57
|
@ -607,4 +607,18 @@ class TestProtectedInterfaceMembers
|
|||
}
|
||||
}
|
||||
|
||||
class TestStaticInterfaceMembers
|
||||
{
|
||||
public static void test_interface_static_member()
|
||||
{
|
||||
var iface = typeof(Dummy.ITestIface);
|
||||
var properties = iface.GetProperties(BindingFlags.Public | BindingFlags.Instance);
|
||||
Test.AssertNull(properties.SingleOrDefault(p => p.Name == "StaticProp"));
|
||||
|
||||
var implementation = typeof(Dummy.TestObject);
|
||||
properties = implementation.GetProperties(BindingFlags.Public | BindingFlags.Static);
|
||||
Test.AssertNotNull(properties.SingleOrDefault(p => p.Name == "StaticProp"));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -3,5 +3,14 @@
|
|||
|
||||
#include "libefl_mono_native_test.h"
|
||||
|
||||
void _dummy_test_iface_static_prop_set(int data EINA_UNUSED)
|
||||
{
|
||||
}
|
||||
|
||||
int _dummy_test_iface_static_prop_get()
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
#include "dummy_test_iface.eo.c"
|
||||
#include "dummy_inherit_iface.eo.c"
|
||||
|
|
|
@ -41,6 +41,14 @@ interface Dummy.Test_Iface
|
|||
}
|
||||
}
|
||||
|
||||
@property static_prop @static {
|
||||
get {}
|
||||
set {}
|
||||
values {
|
||||
data: int;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
events {
|
||||
nonconflicted: void;
|
||||
|
|
Loading…
Reference in New Issue