Commit d4644ca9b1364d3ba34c9b112eeb5317983afe49
Exists in
master
Merge branch 'master' of git.ucsd.edu:110swag/docs
Showing 2 changed files Side-by-side Diff
DesignUseCases.tex
View file @
d4644ca
... | ... | @@ -1137,7 +1137,7 @@ |
1137 | 1137 | {The backend shall save the new mask in models.py.} |
1138 | 1138 | \end{enumerate} |
1139 | 1139 | |
1140 | -{Alternative Workflows:} | |
1140 | +\item [Alternate Workflow] | |
1141 | 1141 | |
1142 | 1142 | \begin{enumerate} |
1143 | 1143 | \itemsep1pt\parskip0pt\parsep0pt |
1144 | 1144 | |
1145 | 1145 | |
... | ... | @@ -1166,14 +1166,12 @@ |
1166 | 1166 | \subsection{[F7] Fix Flashcard} |
1167 | 1167 | |
1168 | 1168 | \begin{description} |
1169 | -\item[Description]{The User shall be able to alter a flashcard he/she made | |
1170 | -originally and not have to make a new copy of it.} | |
1169 | +\item[Description]{The User shall be able to alter a flashcard he/she made originally.} | |
1171 | 1170 | |
1172 | -\item[Desired Outcome]{The User shall alter one flashcard and that | |
1173 | -alteration will be shown to all users of that flashcard} | |
1171 | +\item[Desired Outcome]{The system changes the flashcard in the user's deck so that it | |
1172 | +doesn't affect any other users who added the previous version of the flashcard to their decks.} | |
1174 | 1173 | \\ |
1175 | -\item[User Goals]{The user shall make the flashcard say something different | |
1176 | -than it did originally.} | |
1174 | +\item[User Goals]{The user shall either change the text or the blanks of the flashcard.} | |
1177 | 1175 | |
1178 | 1176 | \item[Primary Actor]{User (student) } |
1179 | 1177 | |
... | ... | @@ -1189,7 +1187,10 @@ |
1189 | 1187 | \begin{itemize} |
1190 | 1188 | \itemsep1pt\parskip0pt\parsep0pt |
1191 | 1189 | \item |
1192 | - {User has created the flashcard} | |
1190 | + {The user has created the flashcard} | |
1191 | +\item | |
1192 | + {The user is either in the feed view or the deck view of a class and can see the | |
1193 | + flashcard that he wishes to fix.} | |
1193 | 1194 | \end{itemize} |
1194 | 1195 | |
1195 | 1196 | \item[Post-conditions]{} |
1196 | 1197 | |
1197 | 1198 | |
1198 | 1199 | |
1199 | 1200 | |
1200 | 1201 | |
1201 | 1202 | |
1202 | 1203 | |
1203 | 1204 | |
1204 | 1205 | |
1205 | 1206 | |
1206 | 1207 | |
... | ... | @@ -1197,39 +1198,44 @@ |
1197 | 1198 | \begin{itemize} |
1198 | 1199 | \itemsep1pt\parskip0pt\parsep0pt |
1199 | 1200 | \item |
1200 | - {The user shall see their alteration for that flashcard} | |
1201 | -\item | |
1202 | - {Other users will be notified of the alteration} | |
1201 | + {The flashcard in the user's deck gets updated to reflect the changes made by the user.} | |
1203 | 1202 | \end{itemize} |
1204 | 1203 | |
1205 | 1204 | \item[Trigger]{User (creator of original card) has clicked on the button |
1206 | -``Edit''} | |
1205 | + blue pencil icon at the bottom left of the flashcard.} | |
1207 | 1206 | |
1208 | 1207 | \item[Workflow] |
1209 | 1208 | |
1210 | 1209 | \begin{enumerate} |
1211 | 1210 | \itemsep1pt\parskip0pt\parsep0pt |
1212 | 1211 | \item |
1213 | - {User shall select one of the Flashcards they authored.} | |
1212 | + {User shall hover over one of the Flashcards they authored.} | |
1214 | 1213 | \item |
1215 | - {User shall select ``Edit'' button on the flashcard.} | |
1214 | + {User shall click on the blue pencil icon at the bottom of the flashcard.} | |
1216 | 1215 | \item |
1217 | - {Client shall display an ``Edit Flashcard'' view.} | |
1216 | + {The frontend shall display a dialog box to edit the flashcard.} | |
1218 | 1217 | \item |
1219 | - {The Flashcard will display editable fields/areas.} | |
1218 | + {The User shall change the text and the blanks of the flashcards appropriately.} | |
1220 | 1219 | \item |
1221 | - {The User shall input any changes to the Flashcard.} | |
1220 | + {The User shall click on the ``Save Changes'' button.} | |
1222 | 1221 | \item |
1223 | - {The User shall select the ``Done Editing'' button.} | |
1222 | + {The frontend shall convert the blanked portion of the text into a list of offsets to be | |
1223 | + sent to the backend in CardGridController.js.} | |
1224 | 1224 | \item |
1225 | - {The Client shall close the ``Edit Flashcard'' view.} | |
1225 | + {The server shall update the flashcards content in FlashcardViewSet.partial_update in views.py.} | |
1226 | 1226 | \item |
1227 | - {The server shall update the Flashcard's content.} | |
1227 | + {The backend makes sure that no other user has the card in question in his/her deck.} | |
1228 | 1228 | \item |
1229 | - {Client shall notify users with the Flashcard that the Flashcard has | |
1230 | - been edited, allowing the other users to keep or to discard the | |
1231 | - changes.} | |
1229 | + {The backend makes the appropriate changes to the card and saves them.} | |
1232 | 1230 | \end{enumerate} |
1231 | +\item[Alternate Workflow] | |
1232 | +\begin{enumerate} | |
1233 | +\itemsep1pt\parskip0pt\parsep0pt | |
1234 | +\item | |
1235 | + {The backend finds that other users have added the card that is being edited.} | |
1236 | +\item | |
1237 | + {The backend shall create a new card with the passed in changes applied and add it to the user's deck | |
1238 | + after removing the older card from the user's deck.} | |
1233 | 1239 | \end{description} |
1234 | 1240 | {} |
1235 | 1241 | |
... | ... | @@ -1410,7 +1416,7 @@ |
1410 | 1416 | |
1411 | 1417 | {} |
1412 | 1418 | |
1413 | -{Alternate Workflow:} | |
1419 | +\item [Alternate Workflow] | |
1414 | 1420 | |
1415 | 1421 | \begin{enumerate} |
1416 | 1422 | \itemsep1pt\parskip0pt\parsep0pt |
... | ... | @@ -1440,8 +1446,7 @@ |
1440 | 1446 | \subsection{[D2] Viewing cards in deck by pull time} |
1441 | 1447 | |
1442 | 1448 | \begin{description} |
1443 | -\item[Description]{The user is able to organize the deck by Flashcards' | |
1444 | -pull timestamps.} | |
1449 | +\item[Description]{The user is able to organize the deck by time stamp.} | |
1445 | 1450 | |
1446 | 1451 | \item[Desired Outcome]{The user views the deck in time ascending/descending |
1447 | 1452 | order.} |
1448 | 1453 | |
1449 | 1454 | |
1450 | 1455 | |
1451 | 1456 | |
1452 | 1457 | |
... | ... | @@ -1450,24 +1455,25 @@ |
1450 | 1455 | |
1451 | 1456 | \item[Primary Actor]{User (student)} |
1452 | 1457 | |
1453 | -\item[Dependency Use Cases]{View by pull timestamp.} | |
1458 | +\item[Dependency Use Cases]{[A1] User Registration, [A2] User Login, [F3] Pull Flashcard, | |
1459 | +[D1] Create Deck} | |
1454 | 1460 | \\ |
1455 | 1461 | \item[Priority Level]{``Must''} |
1456 | 1462 | |
1457 | -\item[Status]{In Progress} | |
1463 | +\item[Status]{Implemented} | |
1458 | 1464 | |
1459 | 1465 | \item[Pre-conditions] |
1460 | 1466 | |
1461 | 1467 | \begin{itemize} |
1462 | 1468 | \itemsep1pt\parskip0pt\parsep0pt |
1463 | 1469 | \item |
1464 | - {User has an account with the application.} | |
1470 | + {The user has an account with the application.} | |
1465 | 1471 | \item |
1466 | - {User is logged in.} | |
1472 | + {The user is logged in.} | |
1467 | 1473 | \item |
1468 | - {User has a deck with at least 1 flashcard.} | |
1474 | + {The user has a deck with at least 1 flashcard.} | |
1469 | 1475 | \item |
1470 | - {User is at the deck view for a class.} | |
1476 | + {The user is at the live feed for a class.} | |
1471 | 1477 | \end{itemize} |
1472 | 1478 | |
1473 | 1479 | \item[Post-conditions] |
1474 | 1480 | |
1475 | 1481 | |
1476 | 1482 | |
1477 | 1483 | |
... | ... | @@ -1478,46 +1484,24 @@ |
1478 | 1484 | {Cards in the deck are in time order.} |
1479 | 1485 | \end{itemize} |
1480 | 1486 | |
1481 | -\item[Trigger]{The User wants to view their cards in a meaningful order.} | |
1487 | +\item[Trigger]{The user wants to view their cards in a meaningful order.} | |
1482 | 1488 | |
1483 | 1489 | \item[Workflow] |
1484 | 1490 | |
1485 | 1491 | \begin{enumerate} |
1486 | 1492 | \itemsep1pt\parskip0pt\parsep0pt |
1493 | +\item {The user shall select the deck view from the navbar.} | |
1487 | 1494 | \item |
1488 | - {The Client shows the user the Deck View.} | |
1489 | -\item | |
1490 | - {The User shall select the option to sort the deck by ascending time.} | |
1491 | -\item | |
1492 | - {The Client shall submit a form POST request to the server at | |
1493 | - /api/deck/ about the order} | |
1494 | -\item | |
1495 | - {The Server shall return the ordered view of the deck.} | |
1496 | -\item | |
1497 | - {The Client displays the cards in the ascending view of the pull | |
1498 | - time.} | |
1495 | + {The frontend renders the view of the deck from the template deck.html.} | |
1499 | 1496 | \end{enumerate} |
1500 | 1497 | |
1498 | +\item[Alternative Workflow] | |
1499 | +\begin {enumerate} | |
1500 | +\item {The user shall select the list view from the navbar.} | |
1501 | +\item {The frontend renders the view of the deck from the template cardlist.html.} | |
1502 | +\end {enumerate} | |
1501 | 1503 | {} |
1502 | 1504 | |
1503 | -{Alternate WorkFlow:} | |
1504 | - | |
1505 | -\begin{enumerate} | |
1506 | -\itemsep1pt\parskip0pt\parsep0pt | |
1507 | -\item | |
1508 | - {The Client shows the user the Deck View.} | |
1509 | -\item | |
1510 | - {The User shall select the option to sort the deck by descending | |
1511 | - time.} | |
1512 | -\item | |
1513 | - {The Client shall submit a form POST request to the server at | |
1514 | - /api/deck/ about the order} | |
1515 | -\item | |
1516 | - {The Server shall return the descending view of the deck.} | |
1517 | -\item | |
1518 | - {The Client displays the cards in the descending view of the pull | |
1519 | - time.} | |
1520 | -\end{enumerate} | |
1521 | 1505 | \end{description} |
1522 | 1506 | \newpage |
1523 | 1507 |
TestCases.tex
View file @
d4644ca
... | ... | @@ -1650,9 +1650,6 @@ |
1650 | 1650 | \item |
1651 | 1651 | {UserX has created a flashcard with the text |
1652 | 1652 | ``This is a bad card too''.} |
1653 | -\item | |
1654 | - {UserX has created a flashcard with the text | |
1655 | -``This is a bad card''.} | |
1656 | 1653 | \end{itemize} |
1657 | 1654 | |
1658 | 1655 | \item[Postconditions:] |
... | ... | @@ -1719,7 +1716,8 @@ |
1719 | 1716 | \item[Desired Outcome:]{The User shall be able to view all the cards in their deck.} |
1720 | 1717 | \\ |
1721 | 1718 | |
1722 | -\item[User Goals:]{To see all pulled cards for easier editing purposes.} | |
1719 | +\item[User Goals:] | |
1720 | +{To view all pulled and created cards in their deck.} | |
1723 | 1721 | |
1724 | 1722 | \item[Dependency Use Cases:]{[A1] User Registration, [A2] User Login, |
1725 | 1723 | [A3] Add a Class, [F1] Push Flashcard, [F3] Pull Flashcard} |
1726 | 1724 | |
1727 | 1725 | |
1728 | 1726 | |
1729 | 1727 | |
1730 | 1728 | |
1731 | 1729 | |
1732 | 1730 | |
1733 | 1731 | |
... | ... | @@ -1732,56 +1730,42 @@ |
1732 | 1730 | \begin{itemize} |
1733 | 1731 | \itemsep1pt\parskip0pt\parsep0pt |
1734 | 1732 | \item |
1735 | - {A browser session is logged in as UserX.} | |
1733 | + {User is logged in as UserX.} | |
1736 | 1734 | \item |
1737 | - {Another browser session is logged in as UserY.} | |
1735 | + {UserX has created a flashcard with the text | |
1736 | +``I made this''.} | |
1738 | 1737 | \item |
1739 | - {UserX and UserY are registered for class TEST 101.} | |
1738 | + {UserX has pulled a flashcard with the text | |
1739 | +``Someone else made this''.} | |
1740 | 1740 | \item |
1741 | - {UserX and UserY are at the feed view for TEST 101.} | |
1741 | + {UserX has added the class TEST 101.} | |
1742 | +\item | |
1743 | + {UserX is at the live feed of TEST 101.} | |
1742 | 1744 | \end{itemize} |
1743 | 1745 | |
1744 | 1746 | \item[Postconditions:] |
1745 | 1747 | \begin{itemize} |
1746 | 1748 | \itemsep1pt\parskip0pt\parsep0pt |
1747 | 1749 | \item |
1748 | - {Cards in the deck are in time order.} | |
1750 | + {None} | |
1749 | 1751 | \end{itemize} |
1750 | 1752 | |
1751 | -\item[Trigger:]{User wants to view a more organized deck.} | |
1753 | +\item[Trigger:]{The User wants to view the result of their adding | |
1754 | +and pulling flashcards.} | |
1752 | 1755 | |
1753 | 1756 | \item[Workflow:] |
1754 | 1757 | \begin{enumerate} |
1755 | 1758 | \itemsep1pt\parskip0pt\parsep0pt |
1759 | + | |
1756 | 1760 | \item |
1757 | - {UserX shall click the ``Compose'' button in the lower right.} | |
1758 | -\item | |
1759 | - {The System shall present a modal with a text box.} | |
1760 | -\item | |
1761 | - {UserX shall type in ``Card A'' and click ``Contribute''.} | |
1762 | -\item | |
1763 | - {The System shall create a new card and add it to the feed.} | |
1764 | -\item | |
1765 | - {UserX shall click the ``Compose'' button in the lower right.} | |
1766 | -\item | |
1767 | - {The System shall present a modal with a text box.} | |
1768 | -\item | |
1769 | - {UserX shall type in ``Card B'' and click ``Contribute''.} | |
1770 | -\item | |
1771 | - {The System shall create a new card and add it to the feed.} | |
1772 | -\item | |
1773 | - {Another User logged in as UserY shall view the feed for TEST 101.} | |
1774 | -\item | |
1775 | - {UserY shall click ``Card B'' to pull the card and add it to their deck.} | |
1776 | -\item | |
1777 | - {UserY shall click ``Card A'' to pull the card and add it to their deck.} | |
1778 | -\item | |
1779 | - {UserY shall go to their Deck View.} | |
1761 | + {UserX shall click on 'Deck', the three vertical cards | |
1762 | +icon on the top left of the screen located on the left of the | |
1763 | +navigation bar.} | |
1780 | 1764 | \end{enumerate} |
1781 | 1765 | |
1782 | -\item[Expected Results]{For UserX the cards are listed in the | |
1783 | - order ``Card B'', ``Card A'' and for UserY they are in the | |
1784 | -deck view as ``Card A'', ``Card B''.} | |
1766 | +\item[Expected Results] | |
1767 | +{UserX shall be at the deck for the class TEST 101 and see the | |
1768 | +cards ``I made this'' and ``Someone else made this''.} | |
1785 | 1769 | |
1786 | 1770 | \end{description} |
1787 | 1771 | \newpage |