"use strict";
var __assign = (this && this.__assign) || function () {
    __assign = Object.assign || function(t) {
        for (var s, i = 1, n = arguments.length; i < n; i++) {
            s = arguments[i];
            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
                t[p] = s[p];
        }
        return t;
    };
    return __assign.apply(this, arguments);
};
exports.__esModule = true;
var ava_1 = require("ava");
var src_1 = require("../src");
ava_1["default"]('isTransfer() returns true for valid transfer.', function (t) {
    var transfer = {
        address: 'JALLWDUOSTSJVL9EEHKW9YQFPBVBJAGLNKRVGSQZCGHQWEMIIILJMTHVAGVDXJVZMBAMOZTSBQNRVNLLSJMPIVGPNE',
        value: 1234,
        message: 'AFDSA',
        tag: 'ASDFDSAFDFDSA'
    };
    t.is(src_1.isTransfer(transfer), true, 'isTransfer() should return true for valid transfer.');
    t.is(src_1.isTransfer(__assign({}, transfer, { message: undefined, tag: undefined })), true, 'isTransfer() should return true for valid transfer with undefined optional fields.');
    t.is(src_1.isTransfer(__assign({}, transfer, { message: '', tag: '' })), true, 'isTransfer() should return true for valid transfer with empty optional fields.');
});
ava_1["default"]('isTransfer() returns false for transfer with invalid address.', function (t) {
    var transfer = {
        address: 'JALLWDUOSTSJVL9EEHKW9YQFPBVBJAGLNKRVGSQZCGHQWEMIIILJMTHVAGVDXJVZMBAMOZTSBQNRVNLLSJMPIVGPNEFSAF',
        value: 1234,
        message: 'AFDSA',
        tag: 'ASDFDSAFDFDSA'
    };
    t.is(src_1.isTransfer(transfer), false, 'isTransfer() should return false for transfer with invalid address.');
});
ava_1["default"]('isTransfer() returns false for transfer with invalid value.', function (t) {
    var transfer = {
        address: 'JALLWDUOSTSJVL9EEHKW9YQFPBVBJAGLNKRVGSQZCGHQWEMIIILJMTHVAGVDXJVZMBAMOZTSBQNRVNLLSJMPIVGPNE',
        value: -10,
        message: 'AFDSA',
        tag: 'ASDFDSAFDFDSA'
    };
    t.is(src_1.isTransfer(transfer), false, 'isTransfer() should return false for transfer with invalid value.');
});
ava_1["default"]('isTransfer() returns false for message of invalid trytes.', function (t) {
    var transfer = {
        address: 'JALLWDUOSTSJVL9EEHKW9YQFPBVBJAGLNKRVGSQZCGHQWEMIIILJMTHVAGVDXJVZMBAMOZTSBQNRVNLLSJMPIVGPNE',
        value: 1234,
        message: 'dffsA',
        tag: 'ASDFDSAFDFDSA'
    };
    t.is(src_1.isTransfer(transfer), false, 'isTransfer() should return false for message of invalid trytes.');
});
ava_1["default"]('isTransfer() returns false for tag of invalid length.', function (t) {
    var transfer = {
        address: 'JALLWDUOSTSJVL9EEHKW9YQFPBVBJAGLNKRVGSQZCGHQWEMIIILJMTHVAGVDXJVZMBAMOZTSBQNRVNLLSJMPIVGPNE',
        value: 1234,
        message: 'AFDSA',
        tag: 'ASDFDSAFDFDSAASFSDFSDFSDFSDF'
    };
    t.is(src_1.isTransfer(transfer), false, 'isTransfer() should return false for tag of invalid length.');
});
ava_1["default"]('isTransfer() returns false for tag of invalid trytes.', function (t) {
    var transfer = {
        address: 'JALLWDUOSTSJVL9EEHKW9YQFPBVBJAGLNKRVGSQZCGHQWEMIIILJMTHVAGVDXJVZMBAMOZTSBQNRVNLLSJMPIVGPNE',
        value: 1234,
        message: 'AFDSA',
        tag: 'sdfASDF'
    };
    t.is(src_1.isTransfer(transfer), false, 'isTransfer() should return false for tag of invalid trytes.');
});
//# sourceMappingURL=isTransfer.test.js.map