Changeset 4490


Ignore:
Timestamp:
May 25, 2007, 2:03:03 PM (17 years ago)
Author:
nick
Message:

re-add lone_vert tests that i accidentally removed

File:
1 edited

Legend:

Unmodified
Added
Removed
  • anuga_core/source/anuga/abstract_2d_finite_volumes/test_util.py

    r4486 r4490  
    12441244
    12451245        check_list(['stage','xmomentum'])
     1246       
     1247    def test_remove_lone_verts_d(self):
     1248        verts = [[0,0],[1,0],[0,1]]
     1249        tris = [[0,1,2]]
     1250        new_verts, new_tris = remove_lone_verts(verts, tris)
     1251        assert new_verts == verts
     1252        assert new_tris == tris
     1253     
     1254
     1255    def test_remove_lone_verts_e(self):
     1256        verts = [[0,0],[1,0],[0,1],[99,99]]
     1257        tris = [[0,1,2]]
     1258        new_verts, new_tris = remove_lone_verts(verts, tris)
     1259        assert new_verts == verts[0:3]
     1260        assert new_tris == tris
     1261       
     1262    def test_remove_lone_verts_a(self):
     1263        verts = [[99,99],[0,0],[1,0],[99,99],[0,1],[99,99]]
     1264        tris = [[1,2,4]]
     1265        new_verts, new_tris = remove_lone_verts(verts, tris)
     1266        #print "new_verts", new_verts
     1267        assert new_verts == [[0,0],[1,0],[0,1]]
     1268        assert new_tris == [[0,1,2]]
     1269     
     1270    def test_remove_lone_verts_c(self):
     1271        verts = [[0,0],[1,0],[99,99],[0,1]]
     1272        tris = [[0,1,3]]
     1273        new_verts, new_tris = remove_lone_verts(verts, tris)
     1274        #print "new_verts", new_verts
     1275        assert new_verts == [[0,0],[1,0],[0,1]]
     1276        assert new_tris == [[0,1,2]]
     1277       
     1278    def test_remove_lone_verts_b(self):
     1279        verts = [[0,0],[1,0],[0,1],[99,99],[99,99],[99,99]]
     1280        tris = [[0,1,2]]
     1281        new_verts, new_tris = remove_lone_verts(verts, tris)
     1282        assert new_verts == verts[0:3]
     1283        assert new_tris == tris
     1284     
     1285
     1286    def test_remove_lone_verts_e(self):
     1287        verts = [[0,0],[1,0],[0,1],[99,99]]
     1288        tris = [[0,1,2]]
     1289        new_verts, new_tris = remove_lone_verts(verts, tris)
     1290        assert new_verts == verts[0:3]
     1291        assert new_tris == tris
     1292
    12461293   
    12471294       
Note: See TracChangeset for help on using the changeset viewer.