         else
           t.pass 'got model builders reply'
           tdiff t, (readGoldJson 'model-builders-kmeans.json'), result, exclude: [ 'model_builders.kmeans.job' ]
-          go null, frameKey, result
+          go null, frameKey
+
+    buildAirlinesKmeansModel = (frameKey, go) ->
+      parameters = src: frameKey, K: 2
+      _.requestModelBuild 'kmeans', parameters, (error, result) ->
+        if error
+          t.fail 'model build request failed'
+          go error
+        else
+          t.pass 'got model build reply'
+          tdiff t, (readGoldJson 'kmeans-allyears2k_headers-zip.json'), result, include: [ 'jobs.#.description', 'jobs.#.dest', 'jobs.#.exception' ]
+          t.ok isString result.key.name, 'has job name'
+          go null, result.key.name
+
+    inspectModel = (modelKey, go) ->
+      _.requestInspect modelKey, (error, result) ->
+        if error
+          t.fail 'model inspect request failed'
+          go error
+        else
+          t.pass 'got model inspect reply'
+          result.schema.parameters[3].actual_value = "(random)"
+          tdiff t, (readGoldJson 'inspect-kmeans-allyears2k_headers-zip.json'), result, exclude: [ 'schema.output.clusters', 'schema.output.rows', 'schema.output.mses', 'schema.output.mse', 'schema.output.iters' ]
+          go null, modelKey
 
     operations = [
       ensureNoFramesExist

    inspectFrame = (frameKey, go) -> 
      _.requestInspect frameKey, (error, result) ->
        if error
          t.fail 'inspect request failed'
          go error
        else
          t.pass 'got inspect reply'
          tdiff t, (readGoldJson 'inspect-allyears2k_headers-zip.json'), result
          go null, frameKey


      inspectFrame
      getFrame
      getKmeansModelBuilder
      buildAirlinesKmeansModel
      pollJob
      inspectModel
    ]
    async.waterfall operations, -> t.end(); go()

