Exemple #1
0
        public void MetaUnset_Ok()
        {
            using var area = new TestArea("metaUnsetOkTest");
            DroneDB.Init(area.TestFolder);

            var f = Path.Join(area.TestFolder, "test.txt");

            File.WriteAllText(f, null);

            DroneDB.Add(area.TestFolder, f);

            DroneDB.MetaSet(area.TestFolder, "abc", "[1,2,3]");
            DroneDB.MetaUnset(area.TestFolder, "abc", f).Should().Be(0);
            DroneDB.MetaUnset(area.TestFolder, "abc").Should().Be(1);
            DroneDB.MetaUnset(area.TestFolder, "abc").Should().Be(0);
        }