Ignore:
Timestamp:
02/06/12 13:52:55 (2 years ago)
Author:
markotoplak
Branch:
default
Children:
9725:6c16952df555, 9752:cbd6f6f10f06
rebase_source:
be8730bf9f2e7e771332dfc8b3876c8a62826bd1
Message:

Renames in Orange.distance.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Orange/testing/unit/tests/test_hclustering.py

    r9679 r9724  
    55                       
    66from Orange.clustering import hierarchical as hier      
    7 from Orange.distance.instances import * 
     7from Orange.distance import * 
    88                            
    99import Orange.misc.testing as testing 
     
    1717    @testing.test_on_data 
    1818    def test_example_clustering_on(self, data): 
    19         constructors = [EuclideanConstructor, ManhattanConstructor] 
     19        constructors = [Euclidean, Manhattan] 
    2020        for distance_constructor in constructors: 
    2121            clust = clustering(data, distance_constructor, HierarchicalClustering.Single) 
     
    3333    @testing.test_on_datasets(datasets=["iris"]) 
    3434    def test_pickling_on(self, data): 
    35         cluster = clustering(data, EuclideanConstructor, HierarchicalClustering.Single) 
     35        cluster = clustering(data, Euclidean, HierarchicalClustering.Single) 
    3636        s = pickle.dumps(cluster) 
    3737        cluster_clone = pickle.loads(s) 
     
    4444            self.assert_(val >= 0 and val <=100) 
    4545            self.assertIsInstance(val, float) 
    46         matrix = instance_distance_matrix(data, EuclideanConstructor(), progress_callback=p) 
     46        matrix = instance_distance_matrix(data, Euclidean(), progress_callback=p) 
    4747        root1 = HierarchicalClustering(matrix, progress_callback=p) 
    4848        root2 = hier.clone(root1) 
Note: See TracChangeset for help on using the changeset viewer.