简体   繁体   English

引用SQLite的Project.json

[英]Project.json referencing SQLite

I would like to convert one of the unit test projects to use a json format of the project file. 我想将一个单元测试项目转换为使用项目文件的json格式。 Unit tests are using NHibernate and SQLite to execute. 单元测试使用NHibernateSQLite执行。 Project.json file looks like this, Project.json文件看起来像这样,

{
  "version": "1.0.0-*",
  "compilationOptions": {
    "emitEntryPoint": true
  },

  "dependencies": {
    "System.Data.SQLite.Core": "1.0.99",
    "NUnit": "3.2.0",
    "NUnitLite": "3.2.0",
    "NSubstitute": "1.9.2"
  },

  "runtimes": {
    "win": { },
    "win-anycpu": {
      "#import": [ "win" ]
    }
  },

  "commands": {
    "test": "Infrastructure.Test"
  },

  "frameworks": {
    "dnx451": {
      "dependencies": {
        "Domain": "1.0.0-*",
        "Infrastructure": "1.0.0-*"
      }
    }
  },

  "exclude": [
  ],
  "publishExclude": [
    "**.user",
    "**.vspscc"
  ],
  "scripts": {
    "prepublish": [ "npm install", "bower install", "gulp clean", "gulp min" ]
  }
}

The problem is when I try to run this, I am getting exception saying Unable to load DLL 'SQLite.Interop.dll': I figure this is because there are 2 different x86 and x64 binaries of the above file shipped with the package and they are located in the build folder. 问题是,当我尝试运行此文件时,出现异常消息,提示Unable to load DLL 'SQLite.Interop.dll':我认为这是因为软件包附带了上述文件的2种不同的x86和x64二进制文件,位于build文件夹中。

How do I get this working? 我该如何工作? Full source can be found here 完整的资料可以在这里找到

run this in Package Manager Console 在Package Manager控制台中运行

PM> Update-Package -reinstall System.Data.SQLite.Core

for detail see this link 有关详细信息,请参见此链接

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM