expand Directory tests

This commit is contained in:
Dane Horn 2022-05-15 09:43:23 +02:00
parent 1a9d3ee998
commit 28dad4dd30

@ -103,6 +103,14 @@ describe("Terminal Directory Tests", function () {
expect(isValidDirectoryName("._foo")).toEqual(true);
expect(isValidDirectoryName("_foo")).toEqual(true);
expect(isValidDirectoryName("foo.dir")).toEqual(true);
expect(isValidDirectoryName("foov1.0.0.1")).toEqual(true);
expect(isValidDirectoryName("foov1..0..0..1")).toEqual(true);
expect(isValidDirectoryName("foov1-0-0-1")).toEqual(true);
expect(isValidDirectoryName("foov1-0-0-1-")).toEqual(true);
expect(isValidDirectoryName("foov1--0--0--1--")).toEqual(true);
expect(isValidDirectoryName("foov1_0_0_1")).toEqual(true);
expect(isValidDirectoryName("foov1_0_0_1_")).toEqual(true);
expect(isValidDirectoryName("foov1__0__0__1")).toEqual(true);
});
it("should return false for invalid directory names", function () {
@ -115,6 +123,7 @@ describe("Terminal Directory Tests", function () {
expect(isValidDirectoryName("..")).toEqual(false);
expect(isValidDirectoryName("1.")).toEqual(false);
expect(isValidDirectoryName("foo.")).toEqual(false);
expect(isValidDirectoryName("foov1.0.0.1.")).toEqual(false);
});
});