Exemplo n.º 1
0
 def testMapPmids2Dois(self):
     self.sess.add(Identifier(1, 'doi', 'id1'))
     self.sess.add(Medline(2, 'MEDLINE', 'Journal', 'PubDate', date.today()))
     self.sess.add(Identifier(2, 'doi', 'id2'))
     self.sess.commit()
     self.assertDictEqual({1: 'id1', 2: 'id2'}, Identifier.mapPmids2Dois([1, 2, 3]))
     self.assertDictEqual({}, Identifier.mapPmids2Dois([3, 4]))
Exemplo n.º 2
0
 def testMapPmids2Dois(self):
     self.sess.add(Identifier(1, 'doi', 'id1'))
     self.sess.add(DefaultCitation(2))
     self.sess.add(Identifier(2, 'doi', 'id2'))
     self.sess.commit()
     self.assertDictEqual({1: 'id1', 2: 'id2'}, Identifier.mapPmids2Dois([1, 2, 3]))
     self.assertDictEqual({}, Identifier.mapPmids2Dois([3, 4]))
Exemplo n.º 3
0
 def testMapPmids2Dois(self):
     self.sess.add(Identifier(1, 'doi', 'id1'))
     self.sess.add(DefaultCitation(2))
     self.sess.add(Identifier(2, 'doi', 'id2'))
     self.sess.commit()
     self.assertDictEqual({
         1: 'id1',
         2: 'id2'
     }, Identifier.mapPmids2Dois([1, 2, 3]))
     self.assertDictEqual({}, Identifier.mapPmids2Dois([3, 4]))
Exemplo n.º 4
0
 def testMapPmids2Dois(self):
     self.sess.add(Identifier(1, 'doi', 'id1'))
     self.sess.add(Medline(2, 'MEDLINE', 'Journal', 'PubDate',
                           date.today()))
     self.sess.add(Identifier(2, 'doi', 'id2'))
     self.sess.commit()
     self.assertDictEqual({
         1: 'id1',
         2: 'id2'
     }, Identifier.mapPmids2Dois([1, 2, 3]))
     self.assertDictEqual({}, Identifier.mapPmids2Dois([3, 4]))