Using the nuget.exe, when restoring dependencies from a virtual repo, artifactory may return the wrong version for the requested dependency.
1.download nuget.exe 3.2
2. download the attached project.json
3. command for mac using the mono framework -
mono --runtime=v4.0.30319 /path/to/nuget.exe restore project.json -source http://localhost:8081/artifactory/api/nuget/nuget-virtual -verbosity detailed
3. command for windows -
nuget restore project.json -source http://localhost:8081/artifactory/api/nuget/nuget-virtual -verbosity detailed
You'll see that it resolves version 2.1.0 of xunit instead of the specified version (which is 2.0.0). One important note is that the virtual repo can aggregate a remote repo proxying the nuget gallery, and when you restore from that remote directly repo you'll get the correct version, but when using the virtual repo, you'll get the wrong version.