Skip to content

Commit c709b9e

Browse files
committed
Updated smoke tests for badge and project app.
1 parent d18f366 commit c709b9e

File tree

2 files changed

+11
-10
lines changed

2 files changed

+11
-10
lines changed

SoftwareTests/PostSmokeTest.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ function PostSmokeTest(ShowReport)
3232
% Format the results in a table and save them
3333
Results = table(Results');
3434
Version = extractBetween(string(Results.Name),"Version=",")");
35-
Passed = Results.Passed;
35+
Passed = logical(Results.Passed);
3636

3737
% Add link to other report
3838
File = fileread(fullfile("public","index.html"));
@@ -51,7 +51,7 @@ function PostSmokeTest(ShowReport)
5151
Badge.message = join("R"+Version," | ");
5252
elseif any(Passed)
5353
Badge.color = "yellowgreen";
54-
Badge.message = join("R")
54+
Badge.message = join("R"+Version(Passed)," | ");
5555
elseif all(~Passed)
5656
Badge.color = "critical";
5757
Badge.message = join("R"+Version," | ");

Utilities/ProjectStartupApp.m

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,9 @@ function saveSettings(isReviewed,numLoad)
9999

100100
% Code that executes after component creation
101101
function startupFcn(app)
102-
102+
103+
% Copy title
104+
app.ReviewTitle.Text = app.WelcomeTitle.Text;
103105

104106
% Switch tab to review if has not been reviewed yet
105107
if isfile(fullfile("Utilities","ProjectSettings.mat"))
@@ -110,11 +112,14 @@ function startupFcn(app)
110112
numLoad = 1; % Initialize counter
111113
end
112114

113-
% Switch tab for review
115+
% Select tab to display
114116
if ~isReviewed && numLoad > 2
115117
isReviewed = true;
116-
app.TabGroup.SelectedTab = app.TabReview;
118+
app.FeedBackGrid.Parent = app.StartUpAppUIFigure;
119+
else
120+
app.WelcomeGrid.Parent = app.StartUpAppUIFigure;
117121
end
122+
app.InitPosition = app.StartUpAppUIFigure.Position;
118123

119124
% Save new settings
120125
app.saveSettings(isReviewed,numLoad)
@@ -135,10 +140,6 @@ function startupFcn(app)
135140
websave(fullfile("Utilities/SurveyLinks.mat"),Answer.Body.Data.download_url);
136141
catch
137142
end
138-
139-
% Prepopulate the App Grid:
140-
app.WelcomeGrid.Parent = app.StartUpAppUIFigure;
141-
app.InitPosition = app.StartUpAppUIFigure.Position;
142143
end
143144

144145
% Close request function: StartUpAppUIFigure
@@ -309,7 +310,7 @@ function createComponents(app)
309310
app.ReviewText = uilabel(app.FeedBackGrid);
310311
app.ReviewText.HorizontalAlignment = 'center';
311312
app.ReviewText.WordWrap = 'on';
312-
app.ReviewText.FontSize = 18;
313+
app.ReviewText.FontSize = 14;
313314
app.ReviewText.Layout.Row = 2;
314315
app.ReviewText.Layout.Column = [1 3];
315316
app.ReviewText.Text = 'Please help us improve your experience by answering a few questions.';

0 commit comments

Comments
 (0)