about summary refs log blame commit diff stats
path: root/test_layers
blob: 09d1e5932c362ce770175b7417074725a3847321 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
           
                                                                            
 
                                               
 
      
 


                             
  
               
                           

    
                                
       
                                                                     
 

                                                           
  
               

                                                                                         


                               
                


           
#!/bin/bash
# Repeatedly stop building until successive layers, and run all tests built.
#
# Assumes .subx files all come after .cc files.

set -e

cd `dirname $0`
# add C++ files one at a time
for f in [0-9]*cc
do
  echo "=== $f"
  ./build_and_test_until $f
done

# build everything one last time
./clean
./build  # build optimized since we'll be running it repeatedly below

# test pure-SubX files (without syntax sugar) one at a time
for f in [012]*.subx
do
  echo "=== $f"
  ./bootstrap translate init.linux $(tools/enumerate --until $f |grep '\.subx$') -o a.elf
  ./bootstrap run a.elf test
  echo
  test `uname` = 'Linux'  &&  {
    chmod +x a.elf
    ./a.elf test
    echo
  } || true
done