コード例 #1
0
def test_swap_resources_into_scope():

    from blaze import data
    t = data([1, 2, 3], dshape='3 * int', name='t')
    scope = swap_resources_into_scope(t.head(2), {})

    assert t._resources()
    assert t in scope
コード例 #2
0
ファイル: test_core_compute.py プロジェクト: leolujuyi/blaze
def test_swap_resources_into_scope():

    from blaze import Data
    t = Data([1, 2, 3], dshape='3 * int', name='t')
    expr, scope = swap_resources_into_scope(t.head(2), {t: t.data})

    assert t._resources()
    assert not expr._resources()

    assert t not in scope
コード例 #3
0
def test_swap_resources_into_scope():

    from blaze import Data
    t = Data([1, 2, 3], dshape='3 * int', name='t')
    expr, scope = swap_resources_into_scope(t.head(2), {t: t.data})

    assert t._resources()
    assert not expr._resources()

    assert t not in scope
コード例 #4
0
 def pipeline_event_loader_args(self, dates):
     (bound_expr,) = super(
         BlazeConsensusEstimatesLoaderNotInteractiveTestCase,
         self,
     ).pipeline_event_loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})
コード例 #5
0
ファイル: test_buyback_auth.py プロジェクト: zzl09/zipline
 def loader_args(self, dates):
     (bound_expr,) = super(
         BlazeCashBuybackAuthLoaderNotInteractiveTestCase,
         self,
     ).loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})
コード例 #6
0
 def loader_args(self, dates):
     (bound_expr,) = super(
         BlazeCashBuybackAuthLoaderNotInteractiveTestCase,
         self,
     ).loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})
コード例 #7
0
 def pipeline_event_loader_args(self, dates):
     (bound_expr, ) = super(
         BlazeShareBuybackAuthLoaderNotInteractiveTestCase,
         self,
     ).pipeline_event_loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})
コード例 #8
0
ファイル: test_earnings.py プロジェクト: jxstanford/zipline
 def loader_args(self, dates):
     (bound_expr,) = super(BlazeEarningsCalendarLoaderNotInteractiveTestCase, self).loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})
コード例 #9
0
ファイル: test_earnings.py プロジェクト: iyangming/zipline
 def loader_args(self, dates):
     (bound_expr, ) = super(
         BlazeEarningsCalendarLoaderNotInteractiveTestCase,
         self,
     ).loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})
コード例 #10
0
ファイル: test_dividends.py プロジェクト: zjc5415/zipline
 def pipeline_event_loader_args(self, dates):
     (bound_expr, ) = super(
         BlazeDividendsByPayDateLoaderNotInteractiveTestCase,
         self,
     ).pipeline_event_loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})
コード例 #11
0
 def pipeline_event_loader_args(self, dates):
     (bound_expr,) = super(
         BlazeShareBuybackAuthLoaderNotInteractiveTestCase,
         self,
     ).pipeline_event_loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})
コード例 #12
0
ファイル: test_dividends.py プロジェクト: AdaoSmith/zipline
 def pipeline_event_loader_args(self, dates):
     (bound_expr,) = super(
         BlazeDividendsByPayDateLoaderNotInteractiveTestCase,
         self,
     ).pipeline_event_loader_args(dates)
     return swap_resources_into_scope(bound_expr, {})