Browse files

[cocos2d] Make sure every single test pass

  • Loading branch information...
1 parent 0f8dbdf commit 18a362d340b1149b6f90dab2e3c3a313febb6c97 @StephaneDelcroix StephaneDelcroix committed Mar 26, 2013
View
13 cocos2d/binding-test-osx/binding-test-osx.csproj
@@ -113,5 +113,18 @@
<Compile Include="..\binding-test\BindingSelectorTest.cs">
<Link>BindingSelectorTest.cs</Link>
</Compile>
+ <Compile Include="TestWindow.cs" />
+ <Compile Include="TestWindow.designer.cs">
+ <DependentUpon>TestWindow.cs</DependentUpon>
+ </Compile>
+ <Compile Include="AssemblyInfo.cs" />
+ </ItemGroup>
+ <ItemGroup>
+ <InterfaceDefinition Include="TestWindow.xib" />
+ </ItemGroup>
+ <ItemGroup>
+ <Content Include="..\binding\cocos2d.dylib">
+ <Link>cocos2d.dylib</Link>
+ </Content>
</ItemGroup>
</Project>
View
17 cocos2d/binding-test/BindingCtorTest.cs
@@ -42,13 +42,13 @@ public class BindingCtorTest : ApiCtorInitTest {
public BindingCtorTest ()
{
// Useful to know what was being tested if the application crash
- // LogProgress = true;
+ LogProgress = true;
// Useful for fixing several errors before rebuilding the bindings
- // ContinueOnFailure = true;
-
+ ContinueOnFailure = true;
+
// Useful to know which types are being skipped for lack of a default ctor
- // LogUntestedTypes = true;
+ LogUntestedTypes = true;
}
static List<object> do_not_dispose = new List<object> ();
@@ -83,7 +83,14 @@ public void Setup ()
//}
protected override Assembly Assembly {
- get { return typeof (CCAccelAmplitude).Assembly; }
+ get {
+ var assembly = typeof (CCAccelAmplitude).Assembly;
+#if MONOMAC
+ MonoMac.ObjCRuntime.Runtime.RegisterAssembly (assembly);
+#endif
+
+ return assembly;
+ }
}
}
}
View
13 cocos2d/binding-test/BindingFieldTest.cs
@@ -38,14 +38,21 @@ public class BindingFieldTest : ApiFieldTest {
public BindingFieldTest ()
{
// Useful to know what was being tried if things crash
- // LogProgress = true;
+ LogProgress = true;
// Useful for fixing several errors before rebuilding the bindings
- // ContinueOnFailure = true;
+ ContinueOnFailure = true;
}
protected override Assembly Assembly {
- get { return typeof (CCAccelAmplitude).Assembly; }
+ get {
+ var assembly = typeof (CCAccelAmplitude).Assembly;
+#if MONOMAC
+ MonoMac.ObjCRuntime.Runtime.RegisterAssembly (assembly);
+#endif
+
+ return assembly;
+ }
}
}
}
View
14 cocos2d/binding-test/BindingSelectorTest.cs
@@ -38,14 +38,21 @@ public class BindingSelectorTest : ApiSelectorTest {
public BindingSelectorTest ()
{
// Useful to know what was being tried if things crash
- // LogProgress = true;
+ LogProgress = true;
// Useful for fixing several errors before rebuilding the bindings
- // ContinueOnFailure = true;
+ ContinueOnFailure = true;
}
protected override Assembly Assembly {
- get { return typeof (CCAccelAmplitude).Assembly; }
+ get {
+ var assembly = typeof (CCAccelAmplitude).Assembly;
+#if MONOMAC
+ MonoMac.ObjCRuntime.Runtime.RegisterAssembly (assembly);
+#endif
+
+ return assembly;
+ }
}
protected override bool Skip (Type type, string selectorName)
@@ -74,6 +81,7 @@ protected override bool Skip (Type type, string selectorName)
case "ccTouchesMoved:withEvent:":
case "ccTouchesEnded:withEvent:":
case "ccTouchesCancelled:withEvent:":
+ case "accelerometer:didAccelerate:":
return type.Name == "CCLayer";
}
return base.Skip (type, selectorName);
View
13 cocos2d/binding-test/BindingSignatureTest.cs
@@ -38,14 +38,21 @@ public class BindingSignatureTest : ApiSignatureTest {
public BindingSignatureTest ()
{
// Useful to know what was being tried if things crash
- // LogProgress = true;
+ LogProgress = true;
// Useful for fixing several errors before rebuilding the bindings
- // ContinueOnFailure = true;
+ ContinueOnFailure = true;
}
protected override Assembly Assembly {
- get { return typeof (CCAccelAmplitude).Assembly; }
+ get {
+ var assembly = typeof (CCAccelAmplitude).Assembly;
+#if MONOMAC
+ MonoMac.ObjCRuntime.Runtime.RegisterAssembly (assembly);
+#endif
+
+ return assembly;
+ }
}
protected override bool Skip (Type type, MethodBase method, string selector)
View
1 cocos2d/binding/.gitignore
@@ -1,4 +1,5 @@
*.dll
*.a
+*.dylib
*.tar.gz
/ios/
View
7 cocos2d/samples/XamMacSample/XamMacSample/HelloWorldLayer.cs
@@ -24,6 +24,13 @@ public HelloWorldLayer () : base (new CCColor4B (0xaa, 0xaa, 0xaa, 0xff))
Add (label);
}
+
+ public override void OnEnter ()
+ {
+ //var sprite = new CCSprite ("Character0") {Position = new PointF (10,10)};
+ //Add (sprite);
+ base.OnEnter ();
+ }
}
}
View
1 cocos2d/samples/XamMacSample/XamMacSample/XamMacSample.csproj
@@ -97,6 +97,7 @@
<Import Project="$(MSBuildExtensionsPath)\Xamarin\Mac\v0.0\Xamarin.Mac.targets" />
<ItemGroup>
<BundleResource Include="Resources\fps_images.png" />
+ <BundleResource Include="Resources\Character0.png" />
</ItemGroup>
<ItemGroup>
<Content Include="..\..\..\binding\cocos2d.dylib">

0 comments on commit 18a362d

Please sign in to comment.