forked from github/server
Repository has moved. Merge branch 'master' of gitolite:eressea
This commit is contained in:
commit
903dfb2b27
|
@ -10,3 +10,5 @@ build-*/
|
|||
ipch/
|
||||
*.log
|
||||
src/Release/
|
||||
game-e3/data/
|
||||
game-e3/reports/
|
||||
|
|
|
@ -0,0 +1,32 @@
|
|||
#!/bin/sh
|
||||
MACHINE=`uname -m`
|
||||
BIN_DIR="build-$MACHINE-Debug"
|
||||
[ -z "$CC" ] && [ ! -z `which gcc` ] && CC="gcc"
|
||||
[ -z "$CC" ] && [ ! -z `which tcc` ] && CC="tcc"
|
||||
[ -z "$CC" ] && [ ! -z `which cc` ] && CC="cc"
|
||||
[ -z "$JOBS" ] && JOBS=1
|
||||
|
||||
DISTCC=`which distcc`
|
||||
if [ ! -z "$DISTCC" ] ; then
|
||||
JOBS=`distcc -j`
|
||||
if [ -z "$JOBS" ] ; then
|
||||
JOBS=1
|
||||
elif [ $JOBS -gt 1 ] ; then
|
||||
CC="distcc $CC"
|
||||
MAKEOPTS=-j$JOBS
|
||||
fi
|
||||
fi
|
||||
echo "Building with $CC and $JOBS jobs"
|
||||
|
||||
mkdir -p $BIN_DIR
|
||||
cd $BIN_DIR
|
||||
CC="$CC" cmake .. -DCMAKE_MODULE_PATH=$PWD/../cmake/Modules -DCMAKE_BUILD_TYPE=Debug
|
||||
make -j$JOBS
|
||||
make test
|
||||
cd ..
|
||||
for GAME in game* ; do
|
||||
cd $GAME
|
||||
ln -sf ../$BIN_DIR/server/server
|
||||
./server -e run_tests
|
||||
cd ..
|
||||
done
|
|
@ -11,7 +11,7 @@ locales = de,en
|
|||
[config]
|
||||
game = e3a
|
||||
source_dir = ..
|
||||
maxnmrs = 10
|
||||
maxnmrs = 20
|
||||
|
||||
[editor]
|
||||
color = 1
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 23d8a36de9cd909aee2aac11c18f9f1311a30b40
|
||||
Subproject commit e9d0875c703291490baec3f582a5b3d30c18f5a0
|
|
@ -179,6 +179,10 @@ function test_ship_capacity()
|
|||
|
||||
update_owners()
|
||||
process_orders()
|
||||
if r2~=u1.region then
|
||||
print(get_turn(), u1, u1.faction)
|
||||
write_reports()
|
||||
end
|
||||
assert_equal(r2, u1.region)
|
||||
assert_not_equal(r2, u2.region)
|
||||
if r2~=u3.region then
|
||||
|
@ -246,13 +250,14 @@ function test_leave()
|
|||
b2.size = 10
|
||||
local u = unit.create(f, r, 1)
|
||||
u.building = b1
|
||||
assert_not_equal(nil, u.building)
|
||||
u:add_item("money", u.number * 100)
|
||||
u:clear_orders()
|
||||
u:add_order("BETRETE BURG " .. itoa36(b2.id))
|
||||
update_owners()
|
||||
process_orders()
|
||||
assert_equal(u.building.id, b1.id, "region owner has left the building") -- region owners may not leave
|
||||
init_reports()
|
||||
write_report(u.faction)
|
||||
print(u.faction)
|
||||
assert_equal(b1, u.building, "region owner has left the building") -- region owners may not leave
|
||||
end
|
||||
|
||||
function test_market()
|
||||
|
|
|
@ -89,6 +89,10 @@ static int parse_args(int argc, char **argv, int *exitcode)
|
|||
case 't':
|
||||
turn = atoi(argv[i][2] ? argv[i]+2 : argv[++i]);
|
||||
break;
|
||||
case 'r':
|
||||
entry_point = "run_turn";
|
||||
turn = atoi(argv[i][2] ? argv[i]+2 : argv[++i]);
|
||||
break;
|
||||
case 'q':
|
||||
verbosity = 0;
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue