Skip to content

Commit

Permalink
fixed openHandles testing error
Browse files Browse the repository at this point in the history
  • Loading branch information
alainwelliver committed Apr 14, 2024
1 parent fa7eab7 commit c5b82de
Show file tree
Hide file tree
Showing 14 changed files with 40 additions and 40 deletions.
20 changes: 10 additions & 10 deletions coverage/clover.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<coverage generated="1713053709992" clover="3.2.0">
<project timestamp="1713053709992" name="All files">
<coverage generated="1713117562844" clover="3.2.0">
<project timestamp="1713117562844" name="All files">
<metrics statements="142" coveredstatements="99" conditionals="24" coveredconditionals="17" methods="17" coveredmethods="11" elements="183" coveredelements="127" complexity="0" loc="142" ncloc="142" packages="4" files="5" classes="5"/>
<package name="src.controller">
<metrics statements="43" coveredstatements="37" conditionals="14" coveredconditionals="14" methods="2" coveredmethods="2"/>
Expand Down Expand Up @@ -104,7 +104,7 @@
<line num="34" count="2" type="stmt"/>
<line num="36" count="12" type="stmt"/>
<line num="43" count="2" type="stmt"/>
<line num="44" count="1" type="stmt"/>
<line num="44" count="2" type="stmt"/>
<line num="48" count="2" type="stmt"/>
</file>
<file name="users.js" path="/Users/alainwelliver/Documents/code-projects/penn-course-projects/sophomore-spring/cis350/Team-8-alain-sem-adam-abhinav-gabe/src/model/users.js">
Expand Down Expand Up @@ -152,17 +152,17 @@
<file name="testUtils.js" path="/Users/alainwelliver/Documents/code-projects/penn-course-projects/sophomore-spring/cis350/Team-8-alain-sem-adam-abhinav-gabe/test/testUtils.js">
<metrics statements="18" coveredstatements="13" conditionals="2" coveredconditionals="1" methods="3" coveredmethods="2"/>
<line num="4" count="2" type="stmt"/>
<line num="16" count="2" type="stmt"/>
<line num="17" count="0" type="stmt"/>
<line num="17" count="2" type="stmt"/>
<line num="18" count="0" type="stmt"/>
<line num="26" count="2" type="stmt"/>
<line num="19" count="0" type="stmt"/>
<line num="27" count="2" type="stmt"/>
<line num="28" count="2" type="stmt"/>
<line num="29" count="2" type="stmt"/>
<line num="30" count="2" type="cond" truecount="1" falsecount="1"/>
<line num="31" count="2" type="stmt"/>
<line num="33" count="0" type="stmt"/>
<line num="36" count="0" type="stmt"/>
<line num="30" count="2" type="stmt"/>
<line num="31" count="2" type="cond" truecount="1" falsecount="1"/>
<line num="32" count="2" type="stmt"/>
<line num="34" count="0" type="stmt"/>
<line num="37" count="0" type="stmt"/>
<line num="46" count="2" type="stmt"/>
<line num="47" count="2" type="stmt"/>
<line num="48" count="2" type="stmt"/>
Expand Down
6 changes: 3 additions & 3 deletions coverage/coverage-final.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion coverage/lcov-report/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ <h1>All files</h1>
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="prettify.js"></script>
<script>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ <h1><a href="../../../index.html">All files</a> src/controller/controllerUtils</
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../../../prettify.js"></script>
<script>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ <h1><a href="../../../index.html">All files</a> / <a href="index.html">src/contr
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../../../prettify.js"></script>
<script>
Expand Down
2 changes: 1 addition & 1 deletion coverage/lcov-report/src/controller/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ <h1><a href="../../index.html">All files</a> src/controller</h1>
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../../prettify.js"></script>
<script>
Expand Down
4 changes: 2 additions & 2 deletions coverage/lcov-report/src/controller/server.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -339,14 +339,14 @@ <h1><a href="../../index.html">All files</a> / <a href="index.html">src/controll
}
});
&nbsp;
module.exports = { app };</pre></td></tr></table></pre>
module.exports = app;</pre></td></tr></table></pre>

<div class='push'></div><!-- for sticky footer -->
</div><!-- /wrapper -->
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../../prettify.js"></script>
<script>
Expand Down
4 changes: 2 additions & 2 deletions coverage/lcov-report/src/model/dbUtils.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ <h1><a href="../../index.html">All files</a> / <a href="index.html">src/model</a
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">2x</span>
<span class="cline-any cline-yes">1x</span>
<span class="cline-any cline-yes">2x</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
Expand Down Expand Up @@ -223,7 +223,7 @@ <h1><a href="../../index.html">All files</a> / <a href="index.html">src/model</a
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../../prettify.js"></script>
<script>
Expand Down
2 changes: 1 addition & 1 deletion coverage/lcov-report/src/model/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ <h1><a href="../../index.html">All files</a> src/model</h1>
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../../prettify.js"></script>
<script>
Expand Down
2 changes: 1 addition & 1 deletion coverage/lcov-report/src/model/users.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ <h1><a href="../../index.html">All files</a> / <a href="index.html">src/model</a
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../../prettify.js"></script>
<script>
Expand Down
2 changes: 1 addition & 1 deletion coverage/lcov-report/test/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ <h1><a href="../index.html">All files</a> test</h1>
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../prettify.js"></script>
<script>
Expand Down
8 changes: 4 additions & 4 deletions coverage/lcov-report/test/testUtils.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ <h1><a href="../index.html">All files</a> / <a href="index.html">test</a> testUt
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">2x</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
Expand Down Expand Up @@ -166,7 +167,6 @@ <h1><a href="../index.html">All files</a> / <a href="index.html">test</a> testUt
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">2x</span>
<span class="cline-any cline-yes">2x</span>
<span class="cline-any cline-yes">2x</span>
Expand All @@ -190,6 +190,7 @@ <h1><a href="../index.html">All files</a> / <a href="index.html">test</a> testUt
fname: 'Adam',
lname: 'Nomani'
};
&nbsp;
/**
* Adds a test student to the DB
* @param {*} testData - the test data
Expand Down Expand Up @@ -223,8 +224,7 @@ <h1><a href="../index.html">All files</a> / <a href="index.html">test</a> testUt
/**
*
* @param {*} db
* @param {*} testData
* @returns
* @returns results from the database
*/
const getDataFromDB = async (db) =&gt; {
try {
Expand All @@ -247,7 +247,7 @@ <h1><a href="../index.html">All files</a> / <a href="index.html">test</a> testUt
<div class='footer quiet pad2 space-top1 center small'>
Code coverage generated by
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
at 2024-04-14T00:15:09.963Z
at 2024-04-14T17:59:22.830Z
</div>
<script src="../prettify.js"></script>
<script>
Expand Down
22 changes: 11 additions & 11 deletions coverage/lcov.info
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ FNF:3
FNH:3
FNDA:2,(anonymous_0)
FNDA:12,(anonymous_1)
FNDA:1,(anonymous_2)
FNDA:2,(anonymous_2)
DA:1,2
DA:4,2
DA:7,2
Expand All @@ -142,7 +142,7 @@ DA:33,12
DA:34,2
DA:36,12
DA:43,2
DA:44,1
DA:44,2
DA:48,2
LF:17
LH:16
Expand Down Expand Up @@ -210,26 +210,26 @@ BRH:0
end_of_record
TN:
SF:test/testUtils.js
FN:16,(anonymous_0)
FN:26,(anonymous_1)
FN:17,(anonymous_0)
FN:27,(anonymous_1)
FN:46,(anonymous_2)
FNF:3
FNH:2
FNDA:0,(anonymous_0)
FNDA:2,(anonymous_1)
FNDA:2,(anonymous_2)
DA:4,2
DA:16,2
DA:17,0
DA:17,2
DA:18,0
DA:26,2
DA:19,0
DA:27,2
DA:28,2
DA:29,2
DA:30,2
DA:31,2
DA:33,0
DA:36,0
DA:32,2
DA:34,0
DA:37,0
DA:46,2
DA:47,2
DA:48,2
Expand All @@ -238,8 +238,8 @@ DA:51,0
DA:56,2
LF:18
LH:13
BRDA:30,0,0,2
BRDA:30,0,1,0
BRDA:31,0,0,2
BRDA:31,0,1,0
BRF:2
BRH:1
end_of_record
2 changes: 1 addition & 1 deletion test/server.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ describe("API endpoint testing", () => {
afterAll(async () => {
// Clean up the database
await deleteTestDataFromDB(db, testUser.username);
await closeMongoDBConnection;
await closeMongoDBConnection();
});

describe("POST /register", () => {
Expand Down

0 comments on commit c5b82de

Please sign in to comment.