Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
it('accepts fantasy-land applicative functors', function() {
assert.isTrue(R.equals(RA.neither(Just(true), Just(true)), Just(false)));
assert.isTrue(R.equals(RA.neither(Just(true), Just(false)), Just(false)));
assert.isTrue(R.equals(RA.neither(Just(false), Just(true)), Just(false)));
assert.isTrue(R.equals(RA.neither(Just(false), Just(false)), Just(true)));
assert.isTrue(R.equals(RA.neither(Just(true), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.neither(Nothing(), Just(true)), Nothing()));
assert.isTrue(R.equals(RA.neither(Nothing(), Just(false)), Nothing()));
assert.isTrue(R.equals(RA.neither(Just(false), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.neither(Nothing(), Nothing()), Nothing()));
});
}
it('accepts fantasy-land applicative functors', function() {
assert.isTrue(R.equals(RA.notBoth(Just(true), Just(true)), Just(false)));
assert.isTrue(R.equals(RA.notBoth(Just(true), Just(false)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(false), Just(true)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(false), Just(false)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(true), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Just(true)), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Just(false)), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Just(false), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Nothing()), Nothing()));
});
}
it('accepts fantasy-land applicative functors', function() {
assert.isTrue(R.equals(RA.notBoth(Just(true), Just(true)), Just(false)));
assert.isTrue(R.equals(RA.notBoth(Just(true), Just(false)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(false), Just(true)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(false), Just(false)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(true), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Just(true)), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Just(false)), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Just(false), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Nothing()), Nothing()));
});
}
it('accepts fantasy-land applicative functors', function() {
assert.isTrue(R.equals(RA.neither(Just(true), Just(true)), Just(false)));
assert.isTrue(R.equals(RA.neither(Just(true), Just(false)), Just(false)));
assert.isTrue(R.equals(RA.neither(Just(false), Just(true)), Just(false)));
assert.isTrue(R.equals(RA.neither(Just(false), Just(false)), Just(true)));
assert.isTrue(R.equals(RA.neither(Just(true), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.neither(Nothing(), Just(true)), Nothing()));
assert.isTrue(R.equals(RA.neither(Nothing(), Just(false)), Nothing()));
assert.isTrue(R.equals(RA.neither(Just(false), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.neither(Nothing(), Nothing()), Nothing()));
});
}
it('accepts fantasy-land applicative functors', function() {
assert.isTrue(R.equals(RA.notBoth(Just(true), Just(true)), Just(false)));
assert.isTrue(R.equals(RA.notBoth(Just(true), Just(false)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(false), Just(true)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(false), Just(false)), Just(true)));
assert.isTrue(R.equals(RA.notBoth(Just(true), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Just(true)), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Just(false)), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Just(false), Nothing()), Nothing()));
assert.isTrue(R.equals(RA.notBoth(Nothing(), Nothing()), Nothing()));
});
}