abuiles / ember-watson

An Ember.js codemod to make upgrades automatic.
https://blog.abuiles.com/ember-watson/
MIT License
305 stars 43 forks source link

Acceptance tests deleted #103

Closed timiyay closed 5 years ago

timiyay commented 8 years ago

I just ran ember-watson on my Ember 2.7.0 codebase for the first time, and it rocks! Hooking it up to CodeClimate now...

I had to revert watson's changes to my acceptance tests, assumedly caused by the destroyApp change: https://github.com/abuiles/ember-watson#tests-use-destroy-app-helper

The end result was that my acceptance test files were emptied, getting rid of all of my test code, and replacing it with a single line

import { module, test } from 'qunit';

The workaround was to git reset changes to any file in tests/acceptance

abuiles commented 8 years ago

pinging @tim-evans

tim-evans commented 8 years ago

Oh man. I thought I caught all these. Will look at this in the am

tim-evans commented 8 years ago

Did you use --dry-run?

tim-evans commented 8 years ago

Oh and for good measure, what version are you running? The current published version of ember-watson doesn't have --dry-run on it.

timiyay commented 8 years ago

@tim-evans no, I didn't use --dry-run. I ran ember help and looked for a --dry-run flag, but didn't see it there.

I installed with ember install ember-watson, so I'm on the latest published version.

It's not mad urgent. Let me know if there's any debug output you'd like me to dig up and post, if you can't find a repro.

Is it as easy as publishing the latest version?

abuiles commented 8 years ago

@tim-evans @timiyay I just published 0.8.3 which includes --dry-run.

@tim-evans sorry about my delay publishing this, I added you as a collaborator on NPM :), just in case I block you again in the future.

tim-evans commented 8 years ago

No blocking me here. I just got a pit in my stomach when I was pinged. Like... oops. Did I mess something up? Haha

timiyay commented 8 years ago

I upgraded to 0.8.3 and ran ember watson:all --dry-run, which showed some output I didn't quite understand:

{ filename: 'tests/acceptance/map/property-test.js' } '\u0000'
{ filename: 'tests/acceptance/map-test.js' } '\u0000'
{ filename: 'tests/acceptance/pro-signup-test.js' } '\u0000'
{ filename: 'tests/unit/controllers/map/property-test.js' } '\u0000'

It appears to be saying "I'm going to do something to these 4 files", but I don't know what \u0000 indicates.

When I ran it for reals, I had the same problem as originally reported - the contents of my acceptance test files were emptied, and replaced with a single line:

import {module, test} from 'qunit';
knownasilya commented 8 years ago

Looks like the result is printed next to the filename, and in this case \u0000 means NULL.

knownasilya commented 7 years ago

Ping @tim-evans

tim-evans commented 7 years ago

@knownasilya humm. That output is for CodeClimate as null terminators

timiyay commented 5 years ago

Closing this issue I opened, as I'm not currently using this addon, and the issue is stale.