push
github
2109 of 13273 relevant lines covered (15.89%)
0.99 hits per line
1 |
class DrugPresenter |
× |
2 |
def initialize(drug) |
× |
3 |
@drug = drug
|
× |
4 |
end
|
× |
5 |
|
|
6 |
def as_json(options = {}) |
× |
7 |
{ |
× |
8 |
id: @drug.id, |
× |
9 |
name: @drug.name, |
× |
10 |
ncit_id: @drug.ncit_id, |
× |
11 |
aliases: @drug.drug_aliases.map{|a| a.name}, |
× |
12 |
} |
× |
13 |
end
|
× |
14 |
end
|
× |