diff --git a/.travis.yml b/.travis.yml
index 8e3d18fdfedcdb8d8b784531857e97837e73c295..0383b4f4fb2f18dadc2c95b0321568f1015f4df7 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -15,7 +15,7 @@ script:
   - make -C unix CC=gcc-4.7
   - make -C unix-cpy CC=gcc-4.7
   - make -C bare-arm
-  - make -C qemu-arm
+  - make -C qemu-arm test
   - make -C stmhal
   - make -C stmhal -B MICROPY_PY_WIZNET5K=1 MICROPY_PY_CC3K=1
   - make -C stmhal BOARD=STM32F4DISC
diff --git a/qemu-arm/Makefile b/qemu-arm/Makefile
index 23222096910989c03329307b7d9c0fccfaa29fb8..0c09dd2ffe59835c8c7ba0f8ad29e44629ee73eb 100644
--- a/qemu-arm/Makefile
+++ b/qemu-arm/Makefile
@@ -12,6 +12,7 @@ CROSS_COMPILE = arm-none-eabi-
 INC =  -I.
 INC += -I..
 INC += -I$(BUILD)
+INC += -I../tools/tinytest/
 
 CFLAGS_CORTEX_M3 = -mthumb -mcpu=cortex-m3
 CFLAGS = $(INC) -Wall -Wpointer-arith -Werror -ansi -std=gnu99 $(CFLAGS_CORTEX_M3) $(COPT) \
@@ -33,15 +34,11 @@ endif
 ## - gcc-arm-none-eabi-4_8-2014q1/share/gcc-arm-none-eabi/samples/src/qemu/Makefile
 LDFLAGS= --specs=nano.specs --specs=rdimon.specs -Wl,--gc-sections -Wl,-Map=$(@:.elf=.map)
 
-ifeq ($(RUN_TESTS), 1)
-SRC_C = \
-	test_main.c \
-
-else
 SRC_C = \
 	main.c \
 
-endif
+SRC_TEST_C = \
+	test_main.c \
 
 SRC_S = \
 
@@ -50,15 +47,21 @@ OBJ += $(PY_O)
 OBJ += $(addprefix $(BUILD)/, $(SRC_C:.c=.o))
 OBJ += $(addprefix $(BUILD)/, $(SRC_S:.s=.o))
 
-ifeq ($(RUN_TESTS), 1)
-INC += -I../tools/tinytest/
-OBJ += $(BUILD)/tinytest.o
-endif
+OBJ_TEST =
+OBJ_TEST += $(PY_O)
+OBJ_TEST += $(addprefix $(BUILD)/, $(SRC_TEST_C:.c=.o))
+OBJ_TEST += $(addprefix $(BUILD)/, $(SRC_S:.s=.o))
+OBJ_TEST += $(BUILD)/tinytest.o
 
 all: run
 
-run: $(BUILD)/flash.elf
-	qemu-system-arm -cpu cortex-m3 -nographic -monitor null -serial null -semihosting -kernel $(BUILD)/flash.elf
+run: $(BUILD)/firmware.elf
+	qemu-system-arm -machine integratorcp -cpu cortex-m3 -nographic -monitor null -serial null -semihosting -kernel $(BUILD)/firmware.elf
+
+test: $(BUILD)/firmware-test.elf
+	qemu-system-arm -machine integratorcp -cpu cortex-m3 -nographic -monitor null -serial null -semihosting -kernel $(BUILD)/firmware-test.elf > $(BUILD)/console.out
+	$(Q)tail -n2 $(BUILD)/console.out
+	$(Q)tail -n1 $(BUILD)/console.out | grep -q "status: 0"
 
 .PHONY: $(BUILD)/genhdr/tests.h
 
@@ -70,8 +73,12 @@ $(BUILD)/tinytest.o:
 	$(Q)$(CC) $(CFLAGS) -DNO_FORKING -o $@ -c ../tools/tinytest/tinytest.c
 
 ## `$(LD)` doesn't seem to like `--specs` for some reason, but we can just use `$(CC)` here.
-$(BUILD)/flash.elf: $(OBJ)
+$(BUILD)/firmware.elf: $(OBJ)
 	$(Q)$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJ) $(LIBS)
 	$(Q)$(SIZE) $@
 
+$(BUILD)/firmware-test.elf: $(OBJ_TEST)
+	$(Q)$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJ_TEST) $(LIBS)
+	$(Q)$(SIZE) $@
+
 include ../py/mkrules.mk
diff --git a/qemu-arm/mpconfigport.h b/qemu-arm/mpconfigport.h
index 45c7737413e2e5356376eef72199d8b1f9270c92..32ed77c1d904f61b3550447176bd0c02c9d9c177 100644
--- a/qemu-arm/mpconfigport.h
+++ b/qemu-arm/mpconfigport.h
@@ -12,8 +12,10 @@
 #define MICROPY_HELPER_REPL         (0)
 #define MICROPY_HELPER_LEXER_UNIX   (0)
 #define MICROPY_ENABLE_SOURCE_LINE  (0)
-#define MICROPY_LONGINT_IMPL        (MICROPY_LONGINT_IMPL_NONE)
+#define MICROPY_LONGINT_IMPL        (MICROPY_LONGINT_IMPL_MPZ)
 #define MICROPY_FLOAT_IMPL          (MICROPY_FLOAT_IMPL_NONE)
+#define MICROPY_PY_BUILTINS_FROZENSET (1)
+#define MICROPY_PY_BUILTINS_MEMORYVIEW (1)
 #define MICROPY_PY_IO               (0)
 
 // type definitions for the specific machine
diff --git a/tools/tinytest-codegen.py b/tools/tinytest-codegen.py
index af2335a9aa6942c0b738e0598a2100aaa4b4bf68..ae6dc19b4e189bf910b82bb6d24746cc8bebedea 100755
--- a/tools/tinytest-codegen.py
+++ b/tools/tinytest-codegen.py
@@ -45,12 +45,14 @@ testgroup_member = (
 )
 
 ## XXX: may be we could have `--without <groups>` argument...
-test_dirs = ('basics', 'float', 'import', 'io', 'misc')
+# currently these tests are selected because they pass on qemu-arm
+test_dirs = ('basics',) # 'float', 'import', 'io', 'misc')
+exclude_tests = ('basics/builtin_override.py', 'basics/class_super_object.py', 'basics/memoryview_gc.py',)
 
 output = []
 
 for group in test_dirs:
-  tests = glob('{}/*.py'.format(group))
+  tests = [test for test in glob('{}/*.py'.format(group)) if test not in exclude_tests]
   output.extend([test_function.format(**script_to_map(test)) for test in tests])
   testcase_members = [testcase_member.format(**chew_filename(test)) for test in tests]
   output.append(testcase_struct.format(name=group, body='\n'.join(testcase_members)))