aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Foiani <sotech117@michaels-mbp-3.lan>2021-04-09 20:31:58 -0400
committerMichael Foiani <sotech117@michaels-mbp-3.lan>2021-04-09 20:31:58 -0400
commit6ecdd804ddb8d2ce2166b71cf0e8929a5a68215e (patch)
tree088a408990a374eb8073526e42d33aa51d9c134a
parent11f0f5457580089eee72b2da9743f9d517341f56 (diff)
Small changes to testing for parsing.
-rw-r--r--data/no_trade_test.xml47
-rw-r--r--src/test/java/edu/brown/cs/student/TransactionTest.java28
-rw-r--r--src/test/java/edu/brown/cs/student/XmlParserTest.java9
3 files changed, 71 insertions, 13 deletions
diff --git a/data/no_trade_test.xml b/data/no_trade_test.xml
new file mode 100644
index 0000000..2031e00
--- /dev/null
+++ b/data/no_trade_test.xml
@@ -0,0 +1,47 @@
+<?xml version="1.0"?>
+<ownershipDocument>
+
+ <schemaVersion>X0306</schemaVersion>
+
+ <documentType>4</documentType>
+
+ <periodOfReport>2021-02-16</periodOfReport>
+
+ <notSubjectToSection16>1</notSubjectToSection16>
+
+ <issuer>
+ <issuerCik>0001708331</issuerCik>
+ <issuerName>Virpax Pharmaceuticals, Inc.</issuerName>
+ <issuerTradingSymbol>VRPX</issuerTradingSymbol>
+ </issuer>
+
+ <reportingOwner>
+ <reportingOwnerId>
+ <rptOwnerCik>0001361013</rptOwnerCik>
+ <rptOwnerName>Bruce Gerald W</rptOwnerName>
+ </reportingOwnerId>
+ <reportingOwnerAddress>
+ <rptOwnerStreet1>1055 WESTLAKES DRIVE, SUITE 300</rptOwnerStreet1>
+ <rptOwnerStreet2></rptOwnerStreet2>
+ <rptOwnerCity>BERWYN</rptOwnerCity>
+ <rptOwnerState>PA</rptOwnerState>
+ <rptOwnerZipCode>19312</rptOwnerZipCode>
+ <rptOwnerStateDescription></rptOwnerStateDescription>
+ </reportingOwnerAddress>
+ <reportingOwnerRelationship>
+ <isDirector>0</isDirector>
+ <isOfficer>1</isOfficer>
+ <isTenPercentOwner>0</isTenPercentOwner>
+ <isOther>0</isOther>
+ <officerTitle>EVP, Commercial Operations</officerTitle>
+ <otherText></otherText>
+ </reportingOwnerRelationship>
+ </reportingOwner>
+
+ <remarks>The Form 3 previously filed on Mr. Bruce's behalf on February 16, 2021 was filed due to an administrative error and is hereby withdrawn. Mr. Bruce is not a director nor executive officer of the Issuer and is not subject to any reporting requirements under Section 16(a) of the Securities Exchange Act of 1934, as amended, with respect to any securities of the Issuer.</remarks>
+
+ <ownerSignature>
+ <signatureName>/s/ Christopher Chipman, attorney-in-fact</signatureName>
+ <signatureDate>2021-04-09</signatureDate>
+ </ownerSignature>
+</ownershipDocument>
diff --git a/src/test/java/edu/brown/cs/student/TransactionTest.java b/src/test/java/edu/brown/cs/student/TransactionTest.java
index f9a00f7..e8b95bc 100644
--- a/src/test/java/edu/brown/cs/student/TransactionTest.java
+++ b/src/test/java/edu/brown/cs/student/TransactionTest.java
@@ -31,20 +31,8 @@ public class TransactionTest {
@Test
public void singleTrade(){
setUp();
- Document doc = _xmlParser.parse("data/xml_single_trade_test.xml");
- assertNotEquals(doc, null);
-
- // One trades in transaction
- Transaction transaction = new Transaction(doc);
- assertEquals(transaction.getTrades().size(), 1);
-
- // TODO: add more qualities on trade to test...
- Trade firstTrade = transaction.getTrades().get(0);
- assertEquals(firstTrade.getNumShares(), 8236);
-
tearDown();
}
-
@Test
public void multipleTrades(){
setUp();
@@ -90,7 +78,21 @@ public class TransactionTest {
@Test
public void noTrades(){
setUp();
- // TODO: add case, but won't realistically come up
+ // TODO: add case from example
tearDown();
}
+
+ @Test
+ public void bad0Trade(){
+ setUp();
+ Document doc = _xmlParser.parse("data/xml_single_trade_test.xml");
+ assertNotEquals(doc, null);
+
+ // One trades in transaction
+ Transaction transaction = new Transaction(doc);
+ assertEquals(transaction.getTrades().size(), 0);
+
+ tearDown();
+ }
+
}
diff --git a/src/test/java/edu/brown/cs/student/XmlParserTest.java b/src/test/java/edu/brown/cs/student/XmlParserTest.java
index 684452b..e6a112f 100644
--- a/src/test/java/edu/brown/cs/student/XmlParserTest.java
+++ b/src/test/java/edu/brown/cs/student/XmlParserTest.java
@@ -165,4 +165,13 @@ public class XmlParserTest {
tearDown();
}
+
+ @Test
+ public void badFormat(){
+ setUp();
+ // TODO: add case
+ tearDown();
+ }
+
+
}