Questions tagged [specs]

The specs is a software's design and the features specification, you can through it to know the software's specifications. General, the open source code will have specs.

If you want to become a contributor for open source lib, through specs you can know how to design the lib, you can write standard code for it.

108 questions
1
vote
1 answer

time dtype in numba-Using time attribute in Numba jitclass spec/ signature

I am using Numba, jitclass to improve my execution time. I am trying to spec time dtype in myClass with jitclass decorator. I tried time, datetime, string, float64/32, numba.NPDattime etc but getting errors. Couldnt find anything in…
ZAK
  • 11
  • 1
  • 2
1
vote
1 answer

How can I write a unit test for the SPECS framework without splitting my code into separate functions?

I'm trying to write tests for my Rust program that is using the SPECS framework. I'm not sure how to run unit tests on the system's run function because it uses the framework's storage types to read values. Does anyone have a good method for getting…
Shizz
  • 43
  • 6
1
vote
1 answer

How to include external source files in a spec to specify measures?

I'm using Specs2 to write a specification for a measurement library. To verify the calculated measures I have numerous source files covering standard cases as well as a lot of corner cases. I did analyze them manually to I know the exact measures,…
Steffen
  • 8,033
  • 1
  • 28
  • 34
1
vote
2 answers

How can you pass a block to have_selector?

I have the following view which I can't spec out properly in a view spec: file: "products/index.html.haml" #products = render @products And this is my view spec: require 'spec_helper' describe "products/index.html.haml" do let(:products)…
dwilkie
  • 583
  • 1
  • 4
  • 9
1
vote
1 answer

How can I share/persist data/status across webdriverio specs?

As per this https://github.com/webdriverio/webdriverio/issues/1500, webdriverio test runner will load the config file for each spec file, which prevents us from persisting/sharing data/status across these specs (and sessions). I'm wondering how it…
Wenzhong Hu
  • 174
  • 1
  • 10
1
vote
0 answers

How to run only failed specs in protractor on re-run option

I am looking for a package that will re-run only failed specs. Which package is better, I saw that protractor-retry and protractor flake are two options, because flake works on all specs on each attempt that will not suit me. Looking something like…
1
vote
1 answer

Iterating over a JSON array in scala

I'm using the JSON lib net.sf.json(http://json-lib.sourceforge.net/apidocs/net/sf/json/package-summary.html) in my scala code. Also, I'm using the specs BDD framework (http://code.google.com/p/specs/) for unit testing. In the doBefore block, i have…
Jim
  • 13
  • 3
1
vote
2 answers

Update global variable with protractor on non-Angular page

Right to it. I have a global variable which I would like to export, so I can use the value in following specs. But since protractor is not working synchronously, export happens before the variable gets updated to the right value. The action is a…
Lex90
  • 39
  • 1
  • 3
1
vote
2 answers

Scala specs: nest in-statements

is it possible to nest following specs test code "ClassX" should { "throw an IllegalArgumentException if n < 0" in { ClassX(-1) must throwA[IllegalArgumentException] } "throw an IllegalArgumentException if n > 50" in { ClassX(51) must…
kiritsuku
  • 52,967
  • 18
  • 114
  • 136
1
vote
1 answer

How to get Spec file logs withoug using ActorLogging

I have test file like this class SomeSpec extends Specification with Specs2RouteTest with SomeService where I have written test cases, its workiing fine. But I am not able to get log messages in log file, so I need to have logging in that spec,…
Sanjay Rabari
  • 2,091
  • 1
  • 17
  • 32
1
vote
0 answers

cannot create executables gcc: ./specs is a directory

I am trying to compile libXaw-1.0.10 , and while configuring i get: gcc: ./specs is a directory I tried to compile a basic helloworld.c and when i created "specs" directory, my compilation failed! What is the cause for this behaviour ? this …
Puneet S. Chauhan
  • 745
  • 1
  • 8
  • 17
1
vote
5 answers

HTML5: HTML VS XHTML spec question regarding comments

In the W3C working draft for HTML5 here's a line I find confusing: http://www.w3.org/TR/html5/introduction.html#html-vs-xhtml Comments that contain the string "-->" can be represented in the DOM but not in the HTML syntax or in XML. I can…
NoozNooz42
  • 4,238
  • 6
  • 33
  • 53
1
vote
2 answers

specs and specs2: how to implement doBefore{} in specs2?

I'm having hard time with "transfering" things in my scala test classes from specs to specs2. Last thing I have is issue with doBefore{} and some "test" in {} My "testing" should { doBefore{} and some "getting" in {} } give me this error Description…
1
vote
1 answer

Sending specs in grunt using grunt-protractor-runner

I am using grunt-protractor-runner plugin and in the protractor target I want to send the specs param containing the test to run. In the grunt file my target looks as follows: testIntegration: { options: { args: { specs:…
1
vote
1 answer

how to use if statement to do a conditional check inside specs?

I have this config/initializer.rb which lets me load a yaml /config/application.yaml and do something like APP_CONFIG["myvar"] how could I enable this for my SPECS also? My goal is to do something like: require "spec_helper" describe BetaController…
Rubytastic
  • 15,001
  • 18
  • 87
  • 175