thejohnfreeman / autocheck

Header-only C++17 library for property-based testing.
ISC License
125 stars 17 forks source link

ERROR: Conanfile not found at /tmp/myautotest/autocheck/[*]@github/thejohnfreeman #16

Open jhgorse opened 10 months ago

jhgorse commented 10 months ago

WSL ubuntu on Windows 10.

[root:/tmp/myautotest] # conan install autocheck/1.0.0@github/thejohnfreeman
ERROR: Conanfile not found at /tmp/myautotest/autocheck/1.0.0@github/thejohnfreeman
[root:/tmp/myautotest] 1 # conan install autocheck/[*]@github/thejohnfreeman
ERROR: Conanfile not found at /tmp/myautotest/autocheck/[*]@github/thejohnfreeman
[root:/tmp/myautotest] 1 # conan search autocheck
conancenter
  ERROR: Recipe 'autocheck' not found
redirectory
  autocheck
    autocheck/1.0.0@github/thejohnfreeman
[root:/tmp/myautotest] # conan search -r redirectory autocheck
redirectory
  autocheck
    autocheck/1.0.0@github/thejohnfreeman

So git clone manually.

conan install autocheck

Next test_requires in the conanfile.py conflicts with new Conan test_requires so the list needs renamed. Try test_requires_list. Here is the error output you would see otherwise:

======== Computing dependency graph ========
ERROR: conanfile.py (autocheck/1.0.0): Error in requirements() method, line 35
        for req in self.test_requires:
        TypeError: 'TestRequirements' object is not iterable

Now we are missing a cupcake.

Requirements
    catch2/3.3.2#99b3464731b1ad237007c24291481c2a:96438105cb542059596be5ff639e510c5c525967#d2e10039f62fb698737aecda6b5bd02f - Download (conancenter)
    cupcake/0.4.1@github/thejohnfreeman#0:efa83b160a55b033c4ea706ddb980cd708e3ba1b - Missing
    gtest/1.13.0#8a0bc5b3e159ed45de97260c2bff65b5:2ccd6652789906cdc03dfd327ec8c127706c87fa#3badccc8c1e2af8cf47ef7c571e856e8 - Download (conancenter)

======== Installing packages ========
ERROR: Missing binary: cupcake/0.4.1@github/thejohnfreeman:efa83b160a55b033c4ea706ddb980cd708e3ba1b

cupcake/0.4.1@github/thejohnfreeman: WARN: Can't find a 'cupcake/0.4.1@github/thejohnfreeman' package binary 'efa83b160a55b033c4ea706ddb980cd708e3ba1b' for the configuration:
[settings]
build_type=Release

ERROR: Missing prebuilt package for 'cupcake/0.4.1@github/thejohnfreeman'. You can try:
    - List all available packages using 'conan list cupcake/0.4.1@github/thejohnfreeman:* -r=remote'
    - Explain missing binaries: replace 'conan install ...' with 'conan graph explain ...'
    - Try to build locally from sources using the '--build=cupcake/0.4.1@github/thejohnfreeman' argument

More Info at 'https://docs.conan.io/2/knowledge/faq.html#error-missing-prebuilt-package'

Fix with --build missing. conan install autocheck/ --build missing

Cheers.

jhgorse commented 10 months ago

Impressive. It actually ran a test.

[root:/tmp/myautotest/build] # ninja tests
[0/2] Re-checking globbed directories...
[14/14] Linking CXX executable output/Debug/bin/autocheck.test.check
[root:/tmp/myautotest/build] # ninja test
[0/2] Re-checking globbed directories...
[0/1] Running tests...
Test project /tmp/myautotest/build
      Start  2: autocheck.test.arbitrary.build
 1/14 Test  #2: autocheck.test.arbitrary.build ...............   Passed    0.02 sec
      Start  1: autocheck.test.arbitrary
 2/14 Test  #1: autocheck.test.arbitrary .....................   Passed    0.00 sec
      Start  4: autocheck.test.check.build
 3/14 Test  #4: autocheck.test.check.build ...................   Passed    0.02 sec
      Start  3: autocheck.test.check
 4/14 Test  #3: autocheck.test.check .........................   Passed    0.00 sec
      Start  6: autocheck.test.generator_combinators.build
 5/14 Test  #6: autocheck.test.generator_combinators.build ...   Passed    0.02 sec
      Start  5: autocheck.test.generator_combinators
 6/14 Test  #5: autocheck.test.generator_combinators .........   Passed    0.00 sec
      Start  8: autocheck.test.generator.build
 7/14 Test  #8: autocheck.test.generator.build ...............   Passed    0.02 sec
      Start  7: autocheck.test.generator
 8/14 Test  #7: autocheck.test.generator .....................   Passed    0.00 sec
      Start 10: autocheck.test.is_one_of.build
 9/14 Test #10: autocheck.test.is_one_of.build ...............   Passed    0.02 sec
      Start  9: autocheck.test.is_one_of
10/14 Test  #9: autocheck.test.is_one_of .....................   Passed    0.00 sec
      Start 12: autocheck.test.largest.build
11/14 Test #12: autocheck.test.largest.build .................   Passed    0.02 sec
      Start 11: autocheck.test.largest
12/14 Test #11: autocheck.test.largest .......................   Passed    0.00 sec
      Start 14: autocheck.test.value.build
13/14 Test #14: autocheck.test.value.build ...................   Passed    0.02 sec
      Start 13: autocheck.test.value
14/14 Test #13: autocheck.test.value .........................   Passed    0.00 sec

100% tests passed, 0 tests failed out of 14

Total Test time (real) =   0.17 sec
[root:/tmp/myautotest/build] # 

Which is more than I can say for our friends at rapidcheck.

jhgorse commented 10 months ago

For the conan.py file fix: https://github.com/thejohnfreeman/autocheck/pull/17