浏览代码

add travis support for python

frabbit 11 年之前
父节点
当前提交
5dd64034f5
共有 3 个文件被更改,包括 8 次插入0 次删除
  1. 1 0
      .travis.yml
  2. 4 0
      tests/RunTravis.hx
  3. 3 0
      tests/unit/compile-python.hxml

+ 1 - 0
.travis.yml

@@ -11,6 +11,7 @@ env:
     - TARGET=neko
     - TARGET=neko
     - TARGET=js
     - TARGET=js
     - TARGET=php
     - TARGET=php
+    - TARGET=python
     - TARGET=cpp
     - TARGET=cpp
     - TARGET=flash9
     - TARGET=flash9
     - TARGET=as3
     - TARGET=as3

+ 4 - 0
tests/RunTravis.hx

@@ -106,6 +106,10 @@ class RunTravis {
 				runCommand("sudo", ["apt-get", "install", "php5", "-y"], true);
 				runCommand("sudo", ["apt-get", "install", "php5", "-y"], true);
 				runCommand("haxe", ["compile-php.hxml"]);
 				runCommand("haxe", ["compile-php.hxml"]);
 				runCommand("php", ["php/index.php"]);
 				runCommand("php", ["php/index.php"]);
+			case "python":
+				runCommand("sudo", ["apt-get", "install", "python3.3", "-y"], true);
+				runCommand("haxe", ["compile-python.hxml"]);
+				runCommand("python3.3", ["unit.py"]);
 			case "cpp":
 			case "cpp":
 				//hxcpp dependencies
 				//hxcpp dependencies
 				runCommand("sudo", ["apt-get", "install", "gcc-multilib", "g++-multilib", "-y"], true);
 				runCommand("sudo", ["apt-get", "install", "gcc-multilib", "g++-multilib", "-y"], true);

+ 3 - 0
tests/unit/compile-python.hxml

@@ -0,0 +1,3 @@
+compile-each.hxml
+unit.Test
+-python unit.py