Skip to content

anonymous /gist:6cd1404bec4c0c49c034
Created

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
it("should test for empty string", function () {
expect(isEmpty('')).toBe(true);
expect(isEmpty(null)).toBe(true);
expect(isEmpty(undefined)).toBe(true);
});
it("should test for non-empty string", function () {
expect(isEmpty('word1')).toBe(false);
});
it("should verify for equality ", function (){
expect(isEqual('word1', 'word1')).toBe(true);
expect(isEqual('word1', 'word2')).toBe(false);
expect(isEqual('word1', ' word1 ')).toBe(false);
expect(isEqual(null, 'word1')).toBe(false);
expect(isEqual('word1', undefined)).toBe(false);
expect(isEqual('', 'word1')).toBe(false);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.