By Developers, For Developers
PDF Pg | Paper Pg | Type | Description | Fixed on | Comments |
---|---|---|---|---|---|
257 | TYPO | The Elixir translation for the key and val generators is missing. I used: def key(), do: oneof([range(1, @cache_size), integer()]) def val(), do: integer() | 2018-09-09 | ||
811 | SUGGEST | MIX_ENV =" test" iex -S mix Fred Hebert. Property-Based Testing with PropEr, Erlang, and Elixir (Kindle Location 811). The Pragmatic Bookshelf, LLC. It would help to point out that you either need to clone proper or run the mix command from deps/proper. Running this from the root of an app that uses proper (such as the one you created earlier in the chapter) will trigger the error: (Mix) Could not start application propcheck: could not find application file: propcheck.app | 2018-10-25 | ||
1875 | TYPO | duplcated should read duplicated Fred Hebert. Property-Based Testing with PropEr, Erlang, and Elixir (Kindle Location 1875). The Pragmatic Bookshelf, LLC. | 2018-10-25 | ||
14 | TYPO | In the first paragraph of the “Running A Property” section, there’s an extra word “a” after the word “have” in the sentence fragment “what we’d have a in a real project”, which appears in about the middle of the paragraph. | 2018-12-07 | ||
5 | TYPO | First excerpt on the web, towards the bottom of page 5, “exmaple” for “example”. I don’t have the book, so I don’t know if it has been fixed already in the book. | 2018-12-07 | ||
30 | SUGGEST | The warning on removing `_build/propcheck.ctex` is probably more useful if it is moved to PDF page 27 after the rebar3 output. Maybe referencing propcheck issue #30 could help give context to those who are curious to know why. | 2018-12-07 | ||
64 | SUGGEST | (Actually, I’m not sure whether it’s a suggestion, typo, or error) Running the Elixir version still returns 50% {bio,{0,300}} most of the time (informally, 7 out of 20); that is nowhere near the output from the Erlang version. | 2018-12-11 | This appears to be a limitation or bug of the utf8() generator directly in PropEr / PropCheck; since PropCheck does not expose the string() generator I don't really know much can be done. | |
76 | SUGGEST | Include the instructions for Elixir developers on running generating samples in iex: $ EXPORT MIX_ENV=test | 2018-12-07 | ||
13 | SUGGEST | Update mix.exs to make propcheck available to both :dev and :test environments, as suggested on propcheck’s GitHub page {:propcheck, “~> 1.1”, only: [:test, :dev]} | 2018-12-07 | ||
329 | TYPO | Many parts of code are formatted wrongly, e.g., code between escapable/1 and the last do_escape/1 are italicized, decode_name/1 are not colored properly and are italicized. | 2018-12-12 | This appears to be a limitation of the PragProg Syntax highlighter for Elixir mishandling strings when using sigils approach (~s| | |
xiii | SUGGEST | Last line of the page: “samples that would take a lot of place”; seems like “place” should be “space”. | 2018-12-07 | ||
xiv | SUGGEST | 2nd paragraph, 3rd sentence: “…, and may not container intermediary steps showed in the text.” Using “shown” seems more common (and comfortable). Please ignore if intended. | 2018-12-07 | ||
2? | SUGGEST | “familiar with thinking and properties” -> “familiar with thinking about properties” ? | 2018-12-07 | ||
3 | SUGGEST | “helping us write them as a user as well as implementers.” -> | 2018-12-07 | ||
137 | SUGGEST | Replace integer() with pos_integer() when generating the price list. Otherwise, the generator will generate negative prices. “Technically”, it’s not wrong (and the tests pass), but feels very wrong in the real world. | 2018-12-11 | This is acknowledged on page 164 of the book (PDF page 172) already in B4. \nIt is a bit of a deliberate choice to use any integer whatsoever, and it's part of illustrating that the tests can be good and the code can work great, but it does not necessarily mean that the solution chosen is apt :) | |
96 | 96 | TYPO | “Commas go between fields of a records”, I think it should be “fields of a record”. 4th item in the spec list, 3rd in the actual page. | 2019-01-11 | |
337 | ERROR | In the Elixir translation of the command/1 callback rewritten to use the shim module, under ‘always_possible’, the arguments for ‘:find_book_by_author_unknown’ and ‘:find_book_by_title_unknown’ should be ‘[author()]’ and ‘[title()]’, respectively, rather than ‘[isbn()]’ Also, under ‘relies_on_state’, the argument for ‘:find_book_by_title_matching’ should be ‘[title(s)]’ instead of ‘[isbn(s)]’ | |||
6 | TYPO | 2nd paragraph: “Let’s take a look at some more-expert work.” … “more-expert” was not hyphenated in B4 and it doesn’t seem like it should be. | 2019-01-14 | ||
79 | TYPO | Between the Erlang and Elixir sample output: | 2019-01-14 | ||
165 | TYPO | First paragraph, second sentence: missing “of” | |||
170 | TYPO | The Elixir code repeats the defintion of strdatetime() and datetime() instead of giving the definition of date() and year() | |||
82 | ERROR | property “symbolic generator” do Should be property “symbolic generator” do or property “symbolic generator” do d needs to be evaluated before it can be passed to :dict.size/1. :proper_gen.eval/1 is not in the 1.3 API docs, but :proper_symb.eval/1 works well. | |||
79 | ERROR | When sampling the test generators in Elixir: iex(3)> :proper_check.sample(PbtGenerators.path()) should be iex(3)> :proper_gen.sample(PbtGenerators.path()) | |||
319 | TYPO | In the “For meeting hours” section “is’t” should be “isn’t”. | |||
41 | ERROR | The combined properties for sorting will test true for a sorting algorithm that doesn’t handle repeated elements correctly, e.g., replacing a repeated element with another already existing element. As an example, sort([1,2,1]) = [1,2,2] is correct according to the properties. The properties given are this too weak. | |||
181 | TYPO | The first paragraph mentions the direction ‘top’ in the two paths. | |||
22 | ERROR | When testing the elixir code for :proper_gen.pick, it is being called with pick/0 which throws an error on iex (UndefinedFunctionError) function :proper_gen.pick/0 is undefined or private. Did you mean one of: * pick/1 (proper) :proper_gen.pick() We need to pass it a generator for it to work properly I guess, e.g :proper_gen.pick(:proper_types.term()) | |||
335 | ERROR | The Elixir translation of the Thinking in Properties sample is badly broken. Most of the ~s sigils are not closed properly. This is obvious when the syntax highlighting has broken down. It starts to go wrong at the end of escapable/1 halfway down the page. escapable/1 should be called escapable?/1 according to normal Elixir styles. | |||
336 | ERROR | body of precondition for :find_book_by_author_unknown should be replaced with not like_author(auth) and body of :find_book_by_title_unknown with not like_title(title) The current version has “not has_isbn(s, xxx)” which do not match Erlang’s version. | |||
50 | TYPO | I think one of the end brackets of the function is missing (it is missing). 5> proper_gen:pick(proper_types:non_empty(proper_types:list(proper_types:number
| |||
216 | TYPO | When outputting state of the system in case of an error “History: #{inspect(history}” is missing a closing bracket. |