Sha256: b256f030e57d229122d5b43161c8ad88f54a16ba77eef6dd093d0051549987a6

Contents?: true

Size: 385 Bytes

Versions: 1

Compression:

Stored size: 385 Bytes

Contents

require 'spec_helper'

describe MicroKanren::MiniKanrenWrappers do
  include MicroKanren::MiniKanrenWrappers
  include MicroKanren::Lisp

  describe "#pull" do
    it "advances the stream until it matures" do
      stream = -> { -> { 42 } }
      pull(stream).must_equal 42
    end

    it "returns nil in the case of the empty stream" do
      pull(nil).must_be_nil
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
micro_kanren-0.0.2 spec/micro_kanren/mini_kanren_wrappers_spec.rb