示例#1
0
    public async Task GetSeriesTest()
    {
        Series data = await FredClient.GetSeries("GNPCA");

        Assert.IsNotNull(data);

        data = await FredClient.GetSeries(DOES_NOT_EXIST);

        Assert.IsNull(data);
    }
    public async Task SeriesTest()
    {
        Series data = (await FredClient.GetSeries("GNPCA"));

        Assert.IsNotNull(data);
        Assert.IsFalse(String.IsNullOrEmpty(data.Symbol));
        Assert.IsFalse(String.IsNullOrEmpty(data.Title));
        Assert.IsFalse(String.IsNullOrEmpty(data.Frequency));
        Assert.IsFalse(String.IsNullOrEmpty(data.Units));
        Assert.IsFalse(String.IsNullOrEmpty(data.SeasonalAdj));
    }