Example #1
0
def testGetFormDPageOfferingInfo():
    dailyIndex = formd.dailyIndex("QTR2", "20190401")
    filteredUrls = dailyIndex.getCikFilteredUrls(['1771428'])[0]
    formD = formd.formD()
    formD.getUrlFromMaster(filteredUrls)
    print("URL: " + formD.url)
    thePage = formD.getFormD()
    assert thePage.status_code == 200, "Should be 200"
    return formD.setFormDOfferingData(thePage)
Example #2
0
def testCheckFullComparison(theQuarter, theDate, theCik):
    #Sample test, theQuarter = "QTR2", theDate = "20190401", theCik = '1771428'
    dailyIndex = formd.dailyIndex(theQuarter, theDate)
    filteredUrls = dailyIndex.getCikFilteredUrls([theCik])[0]
    formD = formd.formD()
    formD.getUrlFromMaster(filteredUrls)
    print("URL: " + formD.url)
    thePage = formD.getFormD()
    assert thePage.status_code == 200, "Should be 200"
    return formD.checkFormDFullComparison(thePage)
Example #3
0
def testInsertFormD():
    dailyIndex = formd.dailyIndex("QTR2", "20190401")
    filteredUrls = dailyIndex.getCikFilteredUrls(['1771428'])[0]
    formD = formd.formD()
    formD.getUrlFromMaster(filteredUrls)
    print("URL is: " + formD.url)
    assert formD.url == "https://www.sec.gov/Archives/edgar/data/1771428/000161577419005115/primary_doc.xml", (
        "Should be 'https://www.sec.gov/Archives/edgar/data/1771428/000161577419005115/primary_doc.xml'"
    )
    formD.insertFormDRecord(filteredUrls)