diff options
author | Christoph Helma <helma@in-silico.ch> | 2016-02-28 12:43:38 +0100 |
---|---|---|
committer | Christoph Helma <helma@in-silico.ch> | 2016-02-28 12:43:38 +0100 |
commit | 8c973e16028cb95c978bb08cf79369a5c3520c31 (patch) | |
tree | 96909cb936fbbf2c3bc43776278953394b93b94f /test/feature.rb | |
parent | b90720cc26d789a96fa6f7a054fe06fc8b4ef33d (diff) |
physchem feature class
Diffstat (limited to 'test/feature.rb')
-rw-r--r-- | test/feature.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/feature.rb b/test/feature.rb index 69204ab..9a8a056 100644 --- a/test/feature.rb +++ b/test/feature.rb @@ -55,4 +55,20 @@ class FeatureTest < MiniTest::Test assert original.smarts, "CN" end + def test_physchem_description + assert_equal 355, PhysChem.descriptors.size + assert_equal 330, PhysChem.unique_descriptors.size + end + + def test_physchem + assert_equal 355, PhysChem.descriptors.size + c = Compound.from_smiles "CC(=O)CC(C)C" + logP = PhysChem.find_or_create_by :name => "Openbabel.logP" + assert_equal 1.6215, logP.calculate(c) + jlogP = PhysChem.find_or_create_by :name => "Joelib.LogP" + assert_equal 3.5951, jlogP.calculate(c) + alogP = PhysChem.find_or_create_by :name => "Cdk.ALOGP.ALogP" + assert_equal 0.35380000000000034, alogP.calculate(c) + end + end |