<commit_before>"use strict";

var Omise = require("../index.js").factory;
var CreditCard = require("42-cent-model").CreditCard;
var Prospect = require("42-cent-model").Prospect;
var assert = require("assert");
var casual = require("casual");
var assign = require("object-assign");

var prospect = new Prospect()
  .withBillingFirstName(casual.first_name)
  .withBillingLastName(casual.last_name)
  .withBillingEmailAddress(casual.email)
  .withBillingPhone(casual.phone)
  .withBillingAddress1(casual.address1)
  .withBillingAddress2(casual.address2)
  .withBillingCity(casual.city)
  .withBillingState(casual.state)
  .withBillingPostalCode("3212")
  .withBillingCountry(casual.country_code)
  .withShippingFirstName(casual.first_name)
  .withShippingLastName(casual.last_name)
  .withShippingAddress1(casual.address1)
  .withShippingAddress2(casual.address2)
  .withShippingCity(casual.city)
  .withShippingState(casual.state)
  .withShippingPostalCode("3212")
  .withShippingCountry(casual.country_code);

var creditCards = {
  visa: new CreditCard()
    .withCreditCardNumber("4111111111111111")
    .withExpirationMonth("11")
    .withExpirationYear("2019")
    .withCvv2("123")
    .withCardHolder(casual.name),
  mastercard: new CreditCard()
    .withCreditCardNumber(casual.card_number("MasterCard"))
    .withExpirationMonth("12")
    .withExpirationYear("2017")
    .withCvv2("123"),
  amex: new CreditCard()
    .withCreditCardNumber(casual.card_number("American Express"))
    .withExpirationMonth("12")
    .withExpirationYear("2017")
    .withCvv2("123"),
  discover: new CreditCard()
    .withCreditCardNumber(casual.card_number("Discover Card"))
    .withExpirationMonth("12")
    .withExpirationYear("2017")
    .withCvv2("123"),
  forbidden: new CreditCard()
    .withCreditCardNumber("5000300020003003")
    .withExpirationMonth("12")
    .withExpirationYear("2017")
    .withCvv2("123")
};

describe("Omise adaptor", function() {
  var service;
<commit_msg>Update valid expiration date in tests<commit_after>"use strict";

var Omise = require("../index.js").factory;
var CreditCard = require("42-cent-model").CreditCard;
var Prospect = require("42-cent-model").Prospect;
var assert = require("assert");
var casual = require("casual");
var assign = require("object-assign");

var prospect = new Prospect()
  .withBillingFirstName(casual.first_name)
  .withBillingLastName(casual.last_name)
  .withBillingEmailAddress(casual.email)
  .withBillingPhone(casual.phone)
  .withBillingAddress1(casual.address1)
  .withBillingAddress2(casual.address2)
  .withBillingCity(casual.city)
  .withBillingState(casual.state)
  .withBillingPostalCode("3212")
  .withBillingCountry(casual.country_code)
  .withShippingFirstName(casual.first_name)
  .withShippingLastName(casual.last_name)
  .withShippingAddress1(casual.address1)
  .withShippingAddress2(casual.address2)
  .withShippingCity(casual.city)
  .withShippingState(casual.state)
  .withShippingPostalCode("3212")
  .withShippingCountry(casual.country_code);

var creditCards = {
  visa: new CreditCard()
    .withCreditCardNumber("4111111111111111")
    .withExpirationMonth("11")
    .withExpirationYear("2021")
    .withCvv2("123")
    .withCardHolder(casual.name),
  mastercard: new CreditCard()
    .withCreditCardNumber(casual.card_number("MasterCard"))
    .withExpirationMonth("12")
    .withExpirationYear("2017")
    .withCvv2("123"),
  amex: new CreditCard()
    .withCreditCardNumber(casual.card_number("American Express"))
    .withExpirationMonth("12")
    .withExpirationYear("2017")
    .withCvv2("123"),
  discover: new CreditCard()
    .withCreditCardNumber(casual.card_number("Discover Card"))
    .withExpirationMonth("12")
    .withExpirationYear("2017")
    .withCvv2("123"),
  forbidden: new CreditCard()
    .withCreditCardNumber("5000300020003003")
    .withExpirationMonth("12")
    .withExpirationYear("2017")
    .withCvv2("123")
};

describe("Omise adaptor", function() {
  var service;

{'fraction_non_alphanumeric': 0.138763197586727, 'fraction_numerical': 0.05128205128205128, 'mean_word_length': 5.459415584415584, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 2, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1143566', 'n_tokens_mistral': 1475, 'n_tokens_neox': 1346, 'n_words': 179}