summaryrefslogtreecommitdiffstats
path: root/toolkit/components/places/tests/unit/test_visitsInDB.js
blob: cbd0a04c4b369cb97f896353d5367b058401d732 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
/* -*- indent-tabs-mode: nil; js-indent-level: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et: */

add_task(async function test_execute() {
  const TEST_URI = uri("http://mozilla.com");

  Assert.equal(0, await PlacesTestUtils.visitsInDB(TEST_URI));
  await PlacesTestUtils.addVisits({ uri: TEST_URI });
  Assert.equal(1, await PlacesTestUtils.visitsInDB(TEST_URI));
  await PlacesTestUtils.addVisits({ uri: TEST_URI });
  Assert.equal(2, await PlacesTestUtils.visitsInDB(TEST_URI));
});