Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] Meteor-stubs spyOn Accounts not working when testing package
    I am facing a weird behavior and I hope you could help me on it.

    I am testing my package using sanjo:jasmine@0.20.2 and velocity:meteor-stubs@1.1.0'
    In my tests I do:

    beforeEach(function () {
    MeteorStubs.install();
    });

    Works well for Meteor.users.

    But when using spyOn on Accounts it doesn't work.
    If I do this in my test method:

    spyOn(Accounts, 'setPassword').and.callFake(function() {
    // do nothing
    });
    var result = MyService.changePassword(user, newPassword);...

    Jonas Aschenbrenner
    @Sanjo

    [testing] Testing user interaction of 2 or more different users
    @legyworks wrote:

              Hi there,

    Currently we are stuck during our testing phase for a application. We need to test the interaction between 2 different users, who both need to log in on the same host and perform some tests. So this test has to go along the lines of this:User 1:log in, wait for matchmaking to find other user,Start chat with other user,Exchange messages,kick user

    And the same goes for user 2:log...

    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] Meteor-stubs spyOn Accounts not working when testing package
    I am facing a weird behavior and I hope you could help me on it.

    I am testing my package using sanjo:jasmine@0.20.2 and velocity:meteor-stubs@1.1.0'
    In my tests I do:

    beforeEach(function () {
    MeteorStubs.install();
    });

    Works well for Meteor.users.

    But when using spyOn on Accounts it doesn't work.
    If I do this in my test method:

    spyOn(Accounts, 'setPassword').and.callFake(function() {
    // do nothing
    });
    var result = MyService.changePassword(user, newPassword);...

    Jonas Aschenbrenner
    @Sanjo

    [testing] Testing package with local dependencies?
    @dalgard wrote:

              I'm trying to run the tests of dalgard:jade with the local version of its dependency, dalgard:jade-compiler, but I can't find anywhere to put a packages folder that will make the former package import the latter from anywhere but Atmosphere.

    Any hints?

            Posts: 1
            Participants: 1
            <a...
    Jonas Aschenbrenner
    @Sanjo

    [testing] Blaze not available in Tinytest?
    @dalgard wrote:

              I think I'm suffering from some kind of conceptual misunderstanding here. I'd like to unit test a global Blaze helper, so I thought I could get it like this:

    Blaze._globalHelpers["myHelper](...)

    But I can't get Blaze in my scope – even though I've added it to the list of used dependencies on the client.

    The only way I've found to access it is through Package.blaze.Blaze.

    What gives?...

    Sam
    @ffxsam
    This message was deleted
    Jonas Aschenbrenner
    @Sanjo

    [testing] Why is documentation on Cucumber so lacking?
    @ffxsam wrote:

              I was trying to look up details on tags such as @focus \(since I don't really understand what it does\). But strangely, Cucumber's official documentation doesn't mention it. It doesn't even mention @dev.

    I'm trying to learn more about BDD and TDD, but having trouble finding resources geared towards Meteor. Cucumber's documentation is limited, and the Meteor Testing Manual only has one practical...

    [testing] Don't understand this Gherkin scenario
    @ffxsam wrote:
    <a href="https://github.com/xolvio/Letterpress/blob/master/app/tests/cucumber/features/Users/View%20premium%20content.feature\#L10-L14">
    
      [github.com](http://github.com)
    </a>
    
    
    <a href="[https://github.com/xolvio/Letterpress/blob/master/app/tests/cucumber/features/Users/View%20premium%20content.feature#L10-L14](https://github.com/xolvio/Letterpress/blob/master/app/tests/cucumber/features/Users/View%20premium%20content.feature#L10-L14)"...
    Jonas Aschenbrenner
    @Sanjo
    [Jonas Aschenbrenner, Velocity] @ffxsam I've answered your question in the forums: https://forums.meteor.com/t/why-is-documentation-on-cucumber-so-lacking/11550/2?u=sanjo
    Jonas Aschenbrenner
    @Sanjo

    [testing] How to populate a test database in velocity/cucumber
    @erichsu wrote:

              I've started using the standard recommended xolvio:cucumber and velocity:html-reporter. 

    I want to test against a fairly big test database. I have a dump of the data created by mongodump, and I usually run a script that does mongorestore to load it into a reset local meteor database.

    I can imagine having a hook in cucumber's this.Before that tells the server to import the .json files by reading...

    Jonas Aschenbrenner
    @Sanjo

    [testing] Having a Cucumber test create a user
    @ffxsam wrote:

              I'm writing a simple user login feature:

    Feature: User Login

    As a user
    I want to be able to log in
    So that I can access my account

    @focus
    Scenario: A successful login
    Given I am on the login page
    And my account exists
    And I am not currently logged in
    When I fill out the username and password fields and click submit
    Then I am redirected to the dashboard

    My question...

    Jonas Aschenbrenner
    @Sanjo

    [testing] Difference between @dev, @watch, and @focus
    @ffxsam wrote:

              I think I understand what @focus does, but I don't understand the other two. I noticed that if I run the following:

    $ meteor --test

    No tests are actually run. I have to do this:

    $ VELOCITY_CI=1 meteor --test

    Do I need to use @dev? I can't find clear documentation on what these different tags do.

            Posts: 1
            Participants: 1
            <a...

    [Velocity Core] Difference between @dev, @watch, and @focus
    @ffxsam wrote:

              I think I understand what @focus does, but I don't understand the other two. I noticed that if I run the following:

    $ meteor --test

    No tests are actually run. I have to do this:

    $ VELOCITY_CI=1 meteor --test

    Do I need to use @dev? I can't find clear documentation on what these different tags do.

            Posts: 1
            Participants: 1
            <a...
    Jonas Aschenbrenner
    @Sanjo
    [testing] Delete post please, delete
    @ffxsam wrote:
              disregard pleasedelete post.
    
            Posts: 1
            Participants: 1
            [Read full topic](https://forums.meteor.com/t/delete-post-please-delete/11688)
    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] What is the correct structure for using mocha to test your package?
    Right now I have:

    Package.describe({
    name: 'parlay:synapsepay',
    version: '0.0.1',
    summary: 'synapse_pay_rest for Meteor',
    git: 'https://github.com/parlaywithme/meteor-synapsepay',
    documentation: 'README.md'
    });

    Package.onUse(function(api) {
    api.versionsFrom('1.2.0.2');
    api.use('coffeescript');
    api.addFiles('synapsepay.coffee');
    });

    Package.onTest(function(api) {
    api.use('coffeescript');
    api.use('mike:mocha-package');
    api.use('parlay:synapsepay');...

    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] What is the correct structure for using mocha to test your package?
    Right now I have:

    Package.describe({
    name: 'parlay:synapsepay',
    version: '0.0.1',
    summary: 'synapse_pay_rest for Meteor',
    git: 'https://github.com/parlaywithme/meteor-synapsepay',
    documentation: 'README.md'
    });

    Package.onUse(function(api) {
    api.versionsFrom('1.2.0.2');
    api.use('coffeescript');
    api.addFiles('synapsepay.coffee');
    });

    Package.onTest(function(api) {
    api.use('coffeescript');
    api.use('mike:mocha-package');
    api.use('parlay:synapsepay');...

    Jonas Aschenbrenner
    @Sanjo

    [testing] How to use globals in Cucumber?
    @ffxsam wrote:

              I'm trying to define a file products.js that will just contain nothing but my test data:

    testData = {}
    testData.products = [
    // ...
    ];

    The problem is, my methods in fixtures.js can't see this variable for some reason. How do I make it global across all JS files in Cucumber?

            Posts: 1
            Participants: 1
            <a...
    Simon Fridlund
    @zimme
    any1 around?
    Olivier
    @otroboe
    Maybe I can help with something
    Simon Fridlund
    @zimme
    Having problems with meteor test-packages —velocity ./. Changes in 1.2 meteor to only trigger phantomjs visit when a mirror sets the state ready which I never get
    meteor/meteor@63df4b1
    I’m using micke:mocha-package to test zimme:active-route
    {
        "msg": "added",
        "collection": "velocityMirrors",
        "id": "j4jx7thpgswoN64yh",
        "fields": {
            "rootUrl": "http://localhost:3000/"
        }
    }
    That’s the only message I’m getting from velocityMirrors, it never updates fields: { state: ‘ready’ } so the phantomjs visist never happens and because of that tests are never triggered to run
    Olivier
    @otroboe
    I cant help you sorry :(
    My tests with phantomjs always fail since 1.1 :s:
    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] Cucumber setup in new Meteor project on Mac and Cloud 9 IDE
    I'm trying to use cucumber (via Velocity) in a brand new Meteor project.

    meteor create cucetest
    cd cucetest
    meteor add xolvio:cucumber
    meteor

    I have tried this on OS X El Capitan 10.11 and also on a brand new Cloud 9 IDE Ubuntu vm (using meteor --port $IP:$PORT).

    Unfortunately, after adding sample features Velocity reports an error, with the cucumber log showing the following:

    [xolvio:cucumber] Bad response from Chimp server.
    { statusCode: 200,
    content: '',
    headers:
    {...

    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] Cucumber setup in new Meteor project on Mac and Cloud 9 IDE
    I'm trying to use cucumber (via Velocity) in a brand new Meteor project.

    meteor create cucetest
    cd cucetest
    meteor add xolvio:cucumber
    meteor

    I have tried this on OS X El Capitan 10.11 and also on a brand new Cloud 9 IDE Ubuntu vm (using meteor --port $IP:$PORT).

    Unfortunately, after adding sample features Velocity reports an error, with the cucumber log showing the following:

    [xolvio:cucumber] Bad response from Chimp server.
    { statusCode: 200,
    content: '',
    headers:
    {...

    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] ReferenceError: Mongo is not defined
    I'm developing a custom package. Please, find package.js contents below

    Package.describe({
    name: 'adigiovanni:one-way-accounts',
    version: '0.0.1',
    summary: 'One Way Accounts',
    git: '',
    documentation: 'README.md',
    });

    Package.onUse(function (api) {
    api.versionsFrom('1.2.0.2');
    api.use('ecmascript');
    api.use('mongo');
    // api.imply('mongo');
    api.addFiles([
    'lib/collections/Accounts.js',
    'lib/methods.js',
    'lib/OneWayAccounts.js',
    ]);...

    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] Why does using Mongo in package tests fail when the package has api.use('mongo')?
    I'm developing a custom package. Its package.js is :

    Package.describe({
    name: 'adigiovanni:one-way-accounts',
    version: '0.0.1',
    summary: 'One Way Accounts',
    git: '',
    documentation: 'README.md',
    });

    Package.onUse(function (api) {
    api.versionsFrom('1.2.0.2');
    api.use('ecmascript');
    api.use('mongo');
    // api.imply('mongo');
    api.addFiles([
    'lib/collections/Accounts.js',
    'lib/methods.js',
    'lib/OneWayAccounts.js',
    ]);
    api.export('OneWayAccounts');
    });...

    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] meteor-testing tutorial fails
    I started the meteor-testing tutorial, but the 2nd automatic generated test fails with:

    TypeError: Cannot call method 'url' of undefined

    So it seems that the client variable is not defined. Did anybody experience similar issues? (btw is there a way to debug this)

    i'm using ubuntu 14.04 with

    Meteor 1.2.0.2
    node v4.0.0
    xolvio:cucumber 0.19.4_1 CucumberJS for Velocity

    Jonas Aschenbrenner
    @Sanjo

    [Newest questions tagged meteor-velocity - Stack Overflow] Velocity test-package with html-reporter won't show anything
    My app is structured in packages, each with their corresponding test suites.
    I've added sanjo:jasmine as my testing engine and velocity:html-reporter, but when I run the following command I receive no output and the browser won't connect to the server in port 3000,

    $ velocity test-package hogares --driver-package velocity:html-reporter@0.9.0

    This is the test part of my package.js

    Package.onTest(function(api) {
    api.use('ecmascript');
    api.use('sanjo:jasmine@0.20.2');...

    Jonas Aschenbrenner
    @Sanjo

    [testing] Meteor:jasmine: How to set up mirror database?
    @thebarty wrote:

              Hi guys, Hi @Sanjo \(/users/sanjo\), 

    I am running jasmine within velocity in an "all-in-packages" structure and I wonder how to get database mirrors to work in order to seperate my development-db from my testrunner-db.

    The velocity-docs talk about velocity taking care of mirror-dbs ( <a href="https://velocity.readme.io/docs/mirrors"...

    Kevin Chen
    @aspin
    hey guys got some basic questions if anyone's around
    namely -- how do I view the velocity created mirror DB?
    Kevin Chen
    @aspin
    also, I'm doing the create a package to generate to fixtures thing
    and the tests are crashing because of conflicting package version (?) can anyone ehelp with that?
    it's basically all of the package that I do api.use on
    Max Bruchmann
    @mxab
    Hi, I'm writing some server side integration tests with jasmine but the mirros log sometimes displays errors like
     While preparing to run:
       /var/folders/50/tv_758991yq9nzjs31k7gsvm0000gn/T/tmp-41833s5Fx0BWIItsF.tmp:
       file not found (settings file)
    Kevin Chen
    @aspin
    anyone around? I'm having weird issues now where my collections aren't loading before my test cases
    Kevin Chen
    @aspin
    e.g. ReferenceError: Timezones is not defined, where Timezones is a collection for me
    Kevin Chen
    @aspin
    also I can't access the velocity issues page -- anyone know what's up with that?
    zVictor
    @zvictor
    the same here... we must have an issue page for this project somewhere
    Thomas Sattlecker
    @littleStudent
    Is anyone able to use velocity with google-maps in the project? I always get No 'Access-Control-Allow-Origin' header is present on the requested resource no matter how i configure browser-policy
    Paul Grever
    @paulgrever
    Quick question - when using Velocity Helpers to spyOnMethod how do expect that it’s been called?
    spyOnMethod(‘methodName’)
    // Then I call a method which calls MethodName
    expect(‘methodName’).toHaveBeenCalled()
    Azizur Rahman
    @azizur
    I am abou
    Azizur Rahman
    @azizur
    I am about to start a new meteor production app.
    what are you using for unit testing?
    ouzza
    @az-iB
    hi , is there any solution to make _uihooks transition smooth with velocity in mobile
    Sam Hatoum
    @samhatoum
    @/all Velocity is dead. Long live testing! If you're interested in testing and producing higher quality software faster, please join our new community here: http://community.xolv.io
    Punita Ojha
    @punitaojha
    This message was deleted