コード例 #1
0
ファイル: subset.py プロジェクト: GillianGrayson/pydnameth
 def test_pass_indexes_num_elems(self):
     self.config.attributes.observables.types = {
         'gender': CommonTypes.any.value
     }
     self.config.attributes_dict = load_attributes_dict(self.config)
     indexes = pass_indexes(self.config, 'gender', CommonTypes.any.value,
                            CommonTypes.any.value)
     self.assertEqual(len(indexes), 729)
コード例 #2
0
ファイル: subset.py プロジェクト: owerbat/pydnameth
 def test_pass_indexes_num_m(self):
     self.config.attributes.observables.types = {'gender': 'M'}
     self.config.attributes_dict = load_observables_dict(self.config)
     indexes = pass_indexes(self.config, 'gender', 'M', 'any')
     self.assertEqual(len(indexes), 341)
コード例 #3
0
ファイル: subset.py プロジェクト: owerbat/pydnameth
 def test_len_list_pass_indexes(self):
     self.config.attributes_dict = load_observables_dict(self.config)
     self.assertEqual(len(pass_indexes(self.config, 'age', 18, CommonTypes.any.value)), 19)