Skip to content

Commit 76e4637

Browse files
committed
refactor: replace edit with edit() syntax for testing
1 parent e4e2d61 commit 76e4637

4 files changed

Lines changed: 14 additions & 2 deletions

File tree

-9 Bytes
Binary file not shown.

Scripts/CommentingCode.mlx

-11 Bytes
Binary file not shown.

SoftwareTests/PreFiles/PreCommentingCode.m

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,9 @@
22
% ---- Known Issues -----
33
KnownIssuesID = "";
44
% ---- Pre-run commands -----
5-
5+
edit = @(str)MyEdit(str);
6+
7+
function MyEdit(str)
8+
assert(exist(str,"file"))
9+
disp("Edit the file " + str)
10+
end

SoftwareTests/PreFiles/PreCommentingCodeSoln.m

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,11 @@
44
% ---- Pre-run commands -----
55

66
addpath(genpath(fullfile(currentProject().RootFolder,...
7-
"InstructorResources","Solutions","FunctionLibrarySoln")))
7+
"InstructorResources","Solutions","FunctionLibrarySoln")))
8+
9+
edit = @(str)MyEdit(str);
10+
11+
function MyEdit(str)
12+
assert(exist(str,"file"))
13+
disp("Edit the file " + str)
14+
end

0 commit comments

Comments
 (0)