Skip to content

Commit f9dc5af

Browse files
RTLcoilstrausr
authored andcommitted
Fixed four inert tests and removed a duplicate one
1 parent d92396b commit f9dc5af

File tree

2 files changed

+4
-12
lines changed

2 files changed

+4
-12
lines changed

test/cloudinary_spec.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -151,15 +151,15 @@ describe("cloudinary", function () {
151151
gravity: "center",
152152
quality: 80,
153153
prefix: "a",
154-
}), `${upload_path}/g_center,p_a,q_80,r_3,x_1,y_2/test`);
154+
})).to.eql(`${upload_path}/g_center,p_a,q_80,r_3,x_1,y_2/test`);
155155
expect(cloudinary.utils.url("test", {
156156
x: 1,
157157
y: 2,
158158
radius: 3,
159159
gravity: "center",
160160
quality: "80:444",
161161
prefix: "a",
162-
}), `${upload_path}/g_center,p_a,q_80:444,r_3,x_1,y_2/test`);
162+
})).to.eql(`${upload_path}/g_center,p_a,q_80:444,r_3,x_1,y_2/test`);
163163
});
164164
it("should support auto value", function () {
165165
expect(cloudinary.utils.url("test", {
@@ -169,15 +169,15 @@ describe("cloudinary", function () {
169169
gravity: "center",
170170
quality: "auto",
171171
prefix: "a",
172-
}), `${upload_path}/g_center,p_a,q_auto,r_3,x_1,y_2/test`);
172+
})).to.eql(`${upload_path}/g_center,p_a,q_auto,r_3,x_1,y_2/test`);
173173
expect(cloudinary.utils.url("test", {
174174
x: 1,
175175
y: 2,
176176
radius: 3,
177177
gravity: "center",
178178
quality: "auto:good",
179179
prefix: "a",
180-
}), `${upload_path}/g_center,p_a,q_auto:good,r_3,x_1,y_2/test`);
180+
})).to.eql(`${upload_path}/g_center,p_a,q_auto:good,r_3,x_1,y_2/test`);
181181
});
182182
});
183183
describe(":radius", function() {

test/utils_spec.js

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -84,14 +84,6 @@ describe("utils", function () {
8484
};
8585
expect([`${authenticated_image.public_id}.jpg`, options]).to.produceUrl(new RegExp(`${authenticated_path}/s--[\\w-]+--/c_crop,h_20,w_10/${expected_transformation}v${authenticated_image.version}/${authenticated_image.public_id}.jpg`)).and.emptyOptions().and.beServedByCloudinary(done);
8686
});
87-
it("should correctly sign URL with transformation", function (done) {
88-
options.transformation = {
89-
crop: "crop",
90-
width: 10,
91-
height: 20, // TODO duplicate?
92-
};
93-
expect([`${authenticated_image.public_id}.jpg`, options]).to.produceUrl(new RegExp(`${authenticated_path}/s--[\\w-]+--/c_crop,h_20,w_10/${expected_transformation}v${authenticated_image.version}/${authenticated_image.public_id}.jpg`)).and.emptyOptions().and.beServedByCloudinary(done);
94-
});
9587
it("should correctly sign fetch URL", function (done) {
9688
options.type = "fetch";
9789
expect(["http://res.cloudinary.com/demo/sample.png", options]).to.produceUrl(new RegExp(`^${root_path}/image/fetch/s--[\\w-]+--/${expected_transformation}v${authenticated_image.version}/http://res.cloudinary.com/demo/sample.png$`)).and.emptyOptions().and.beServedByCloudinary(done);

0 commit comments

Comments
 (0)