Skip to content

Instantly share code, notes, and snippets.

@cohitre
Created November 14, 2014 23:11
Show Gist options
  • Save cohitre/168c23f168a9b8bc4aea to your computer and use it in GitHub Desktop.
Save cohitre/168c23f168a9b8bc4aea to your computer and use it in GitHub Desktop.
test('#isOrdersRequired', function() {
var t = function(dateStr, expectedValue) {
var mp = Marketplace.create({
created_at: dateStr
});
deepEqual(mp.get("isOrdersRequired"), expectedValue, "Date %@ isOrdersRequired".fmt(dateStr));
};
t("2014-06-10T02:15:39.415520Z", false);
t("2014-11-07T00:00:00.000000Z", false);
t("2014-11-07T00:00:01Z", true);
t("2014-11-10T02:15:39.415520Z", true);
t("2014-11-10T02:15:39.415520Z", true);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment