forked from FEMR/femr
-
Notifications
You must be signed in to change notification settings - Fork 0
admin ui MVC set up #5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
siriwans
wants to merge
6
commits into
master
Choose a base branch
from
siri_405
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
a7d8fcd
admin ui MVC set up
siriwans b63e4f0
i dont want to break this
mmachiya 6254ba4
deleted unecessary file
siriwans 97ee7f8
pr comments
siriwans 93fd02e
Merge branch 'siri_405' of https://github.com/CPSECapstone/femr into …
siriwans 23543a5
more pr comments
siriwans File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
33 changes: 33 additions & 0 deletions
33
test/unit/app/femr/data/models/mysql/DatabaseStatusTest.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package unit.app.femr.data.models.mysql; | ||
|
||
import femr.data.models.mysql.DatabaseStatus; | ||
import org.junit.Before; | ||
import org.junit.Test; | ||
import static org.junit.Assert.assertEquals; | ||
|
||
public class DatabaseStatusTest { | ||
DatabaseStatus ds; | ||
|
||
@Before | ||
public void setUp() { | ||
ds = new DatabaseStatus(); | ||
} | ||
|
||
@Test | ||
public void checkId(){ | ||
ds.setId(123); | ||
assertEquals(123, ds.getId()); | ||
} | ||
|
||
@Test | ||
public void checkName(){ | ||
ds.setName("very cool database"); | ||
assertEquals("very cool database", ds.getName()); | ||
} | ||
|
||
@Test | ||
public void checkValue(){ | ||
ds.setValue("connected"); | ||
assertEquals("connected", ds.getValue()); | ||
} | ||
} | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package unit.app.femr.data.models.mysql; | ||
|
||
import femr.data.models.mysql.KitStatus; | ||
import org.junit.Before; | ||
import org.junit.Test; | ||
import static org.junit.Assert.assertEquals; | ||
|
||
public class KitStatusTest { | ||
KitStatus ks; | ||
|
||
@Before | ||
public void setUp() { | ||
ks = new KitStatus(); | ||
} | ||
|
||
@Test | ||
public void checkId(){ | ||
ks.setId(123); | ||
assertEquals(123, ks.getId()); | ||
} | ||
|
||
@Test | ||
public void checkName(){ | ||
ks.setName("KitA"); | ||
assertEquals("KitA", ks.getName()); | ||
} | ||
|
||
@Test | ||
public void checkValue(){ | ||
ks.setValue("deployed"); | ||
assertEquals("deployed", ks.getValue()); | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package unit.app.femr.data.models.mysql; | ||
|
||
import femr.data.models.mysql.KitUpdate; | ||
import org.junit.Before; | ||
import org.junit.Test; | ||
import static org.junit.Assert.assertEquals; | ||
|
||
public class KitUpdateTest { | ||
KitUpdate ku; | ||
|
||
@Before | ||
public void setUp() { | ||
ku = new KitUpdate(); | ||
} | ||
|
||
@Test | ||
public void checkId(){ | ||
ku.setId(123); | ||
assertEquals(123, ku.getId()); | ||
} | ||
|
||
@Test | ||
public void checkName(){ | ||
ku.setName("new schema update"); | ||
assertEquals("new schema update", ku.getName()); | ||
} | ||
|
||
@Test | ||
public void checkValue(){ | ||
ku.setValue("completed"); | ||
assertEquals("completed", ku.getValue()); | ||
} | ||
} |
34 changes: 34 additions & 0 deletions
34
test/unit/app/femr/data/models/mysql/NetworkStatusTest.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package unit.app.femr.data.models.mysql; | ||
|
||
import femr.data.models.mysql.NetworkStatus; | ||
import org.junit.Before; | ||
import org.junit.Test; | ||
import static org.junit.Assert.assertEquals; | ||
|
||
public class NetworkStatusTest { | ||
NetworkStatus nt; | ||
|
||
@Before | ||
public void setUp() { | ||
nt = new NetworkStatus(); | ||
} | ||
|
||
@Test | ||
public void checkId(){ | ||
nt.setId(123); | ||
assertEquals(123, nt.getId()); | ||
} | ||
|
||
@Test | ||
public void checkName(){ | ||
nt.setName("NetworkA"); | ||
assertEquals("NetworkA", nt.getName()); | ||
} | ||
|
||
@Test | ||
public void checkValue(){ | ||
nt.setValue("connected"); | ||
assertEquals("connected", nt.getValue()); | ||
} | ||
|
||
} |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the tests look good, they test exactly what we need right now