Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
conditionals_homework
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SOFT Core
SOFT 160
conditionals_homework
Commits
a891119b
Commit
a891119b
authored
Sep 21, 2020
by
Christopher Bohn
Browse files
Options
Downloads
Patches
Plain Diff
Corrected test names in CaucusTest, updated due date
parent
3efdf940
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.md
+1
-1
1 addition, 1 deletion
README.md
src/test/java/edu/unl/cse/soft160/conditionals/CaucusTest.java
+40
-24
40 additions, 24 deletions
...est/java/edu/unl/cse/soft160/conditionals/CaucusTest.java
with
41 additions
and
25 deletions
README.md
+
1
−
1
View file @
a891119b
...
@@ -236,7 +236,7 @@ This assignment is worth **16 points**:
...
@@ -236,7 +236,7 @@ This assignment is worth **16 points**:
test cases provided, and
test cases provided, and
*
**1.0 point**
if your solution to Part II uses a single conditional.
*
**1.0 point**
if your solution to Part II uses a single conditional.
The assignment is due
Mon
day, September
28
at 9:00
a.m.
The assignment is due
Wednes
day, September
30
at 9:00
a.m.
**
NOTE: You will lose 2 points if you do not follow the file-naming conventions
**
NOTE: You will lose 2 points if you do not follow the file-naming conventions
listed in the instructions.
**
listed in the instructions.
**
This diff is collapsed.
Click to expand it.
src/test/java/edu/unl/cse/soft160/conditionals/CaucusTest.java
+
40
−
24
View file @
a891119b
...
@@ -27,58 +27,74 @@ public class CaucusTest {
...
@@ -27,58 +27,74 @@ public class CaucusTest {
}
}
@Test
@Test
public
void
test
AcquireWithNoRotation
()
{
public
void
test
InvalidReportNotOnCaucusDay
()
{
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"no"
,
"no"
,
"no"
));
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"no"
,
"no"
,
"no"
));
}
}
@Test
@Test
public
void
test
AcquireWithSTTRotation
()
{
public
void
test
TelephoneReportNotOnCaucusDay
()
{
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"no"
,
"no"
,
"yes"
));
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"no"
,
"no"
,
"yes"
));
}
}
@Test
@Test
public
void
test
AcquireWithIRURotation
()
{
public
void
test
WellFormattedElectronicReportNotOnCaucusDay
()
{
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"no"
,
"yes"
,
"no"
));
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"no"
,
"yes"
,
"no"
));
}
}
@Test
@Test
public
void
test
AcquireWithRotation
()
{
public
void
test
DuplicatedReportNotOnCaucusDay
()
{
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"no"
,
"yes"
,
"yes"
));
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"no"
,
"yes"
,
"yes"
));
}
}
@Test
@Test
public
void
test
TrackWithNoRotation
()
{
public
void
test
InvalidReportOnCaucusDay
()
{
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"yes"
,
"no"
,
"no"
));
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Precinct report rejected"
),
runMain
(
"yes"
,
"no"
,
"no"
));
}
}
@Test
@Test
public
void
testT
rackWithSTTRotation
()
{
public
void
testT
elephoneReportOnCaucusDay
()
{
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Precinct report accepted"
),
runMain
(
"yes"
,
"no"
,
"yes"
));
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Precinct report accepted"
),
runMain
(
"yes"
,
"no"
,
"yes"
));
}
}
@Test
@Test
public
void
test
TrackWithIRURotation
()
{
public
void
test
WellFormattedElectronicReportOnCaucusDay
()
{
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Precinct report accepted"
),
runMain
(
"yes"
,
"yes"
,
"no"
));
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Precinct report accepted"
),
runMain
(
"yes"
,
"yes"
,
"no"
));
}
}
@Test
@Test
public
void
test
TrackWithRotation
()
{
public
void
test
DuplicatedReportOnCaucusDay
()
{
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
assertEquals
(
assemble
(
"Is today a caucus day (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Is the precinct report a correctly-formatted electronic report (yes/no)? "
+
"Precinct report accepted"
),
runMain
(
"yes"
,
"yes"
,
"yes"
));
+
"Is the precinct report a telephoned report (yes/no)? "
+
"Precinct report accepted"
),
runMain
(
"yes"
,
"yes"
,
"yes"
));
}
}
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment