     :balance 2000M}])
 
 (deftest import-a-simple-file
-  (let [context (serialization/realize storage-spec import-context)
+  (let [context (serialization/realize
+                  storage-spec
+                  (import-context :gnucash))
         user (-> context :users first)
         image (-> context :images first)
         imp (-> context :imports first)


(use-fixtures :each (partial reset-db storage-spec))

(def gnucash-sample
  (io/input-stream "resources/fixtures/sample.gnucash"))

(def import-context
  {:users [(factory :user, {:email "john@doe.com"})]
   :images [{:body (read-bytes gnucash-sample)
             :content-type "application/gnucash"
             :original-filename "sample.gnucash"}]
   :imports [{:entity-name "Personal"
              :image-id "sample.gnucash"}]})


            [clj-time.core :as t]
            [environ.core :refer [env]]
            [clj-factory.core :refer [factory]]
            [clj-money.util :refer [file-ext
                                    file-name]]
            [clj-money.io :refer [read-bytes]]
            [clj-money.serialization :as serialization]
            [clj-money.factories.user-factory]
