Description
LiteCore API Native.c4doc_getExpiration(_c4db, docId, &err2); did not return the expected long value (represent date time) instead it returns 0.
After update to LiteCore to
CE: f375a7fbbce062b7f3058a5c42de1befe8ee7dba
.Net test:
public void TestGetExpirationFromDeletedDoc()
{
DateTimeOffset dto3 = DateTimeOffset.UtcNow.AddSeconds(3);
using (var doc1a = new MutableDocument("deleted_doc"))
{ doc1a.SetInt("answer", 12); doc1a.SetValue("options", new[]
);
Db.Save(doc1a);
Db.SetDocumentExpiration("deleted_doc", dto3).Should().Be(true);
Db.Delete(doc1a);
}
var exp = Db.GetDocumentExpiration("deleted_doc");
exp.Should().BeSameDateAs(dto3); <-- failed exp is null value instead of expected date time value.
}