Commit graph

172 commits

Author SHA1 Message Date
Ben Gotow cbfe310521 fix(eslint): Avoid eslint/eslint/issues/5125 by specifying escope version 2016-02-01 11:08:15 -08:00
mbilker 9458df3a9c bump(grunt-contrib-csslint): update to ~0.5.0 2016-02-01 10:10:12 -05:00
Evan Morikawa 983dc77ef0 fix(resources): update build resources link 2016-01-28 12:03:23 -08:00
Evan Morikawa 8bcb0a2184 fix(resources): update build resources link 2016-01-28 12:02:27 -08:00
Evan Morikawa 55aedef697 feat(startup): new option to launch on system start
Summary:
adds new option to launch on system start

Also adds the `--background` flag to launch N1 in the background (aka not
show the main window).

Test Plan: Manual

Reviewers: bengotow, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D2474
2016-01-28 12:02:08 -08:00
Juan Tejada 7e368a74d2 update(analytics): Add missing action: removeAttachment 2016-01-28 11:02:27 -08:00
Ben Gotow 7ef187e882 Update analytics to remove references to deleted Actions 2016-01-28 10:38:02 -08:00
Ben Gotow 205ec50b98 Fix AccountStore.current() references in private packages 2016-01-25 18:02:56 -08:00
Ben Gotow e2234bf58e Merge branch 'master' into unified-inbox
# Conflicts:
#	internal_packages/feedback/lib/feedback-button.cjsx
#	internal_packages/thread-list/lib/thread-list.cjsx
#	src/flux/stores/draft-store.coffee
2016-01-25 17:28:29 -08:00
Evan Morikawa 6695de4187 feat(tasks): add Create, Update, Destroy tasks plus spec & lint fixes
Summary:
1. **Generic CUD Tasks**: There is now a generic `CreateModelTask`,
`UpdateModelTask`, and `DestroyModelTask`. These can either be used as-is
or trivially overridden to easily update simple objects. Hopefully all of
the boilerplate rollback, error handling, and undo logic won't have to be
re-duplicated on every task. There are also tests for these tasks. We use
them to perform mutating actions on `Metadata` objects.

1. **Failing on Promise Rejects**: Turns out that if a Promise rejected
due to an error or `Promise.reject` we were ignoring it and letting tests
pass. Now, tests will Fail if any unhandled promise rejects. This
uncovered a variety of errors throughout the test suite that had to be
fixed. The most significant one was during the `theme-manager` tests when
all packages (and their stores with async DB requests) was loaded. Long
after the `theme-manager` specs finished, those DB requests were
(somtimes) silently failing.

1. **Globally stub `DatabaseStore._query`**: All tests shouldn't actually
make queries on the database. Furthremore, the `inTransaction` block
doesn't resolve at all unless `_query` is stubbed. Instead of manually
remembering to do this in every test that touches the DB, it's now mocked
in `spec_helper`. This broke a handful of tests that needed to be manually
fixed.

1. **ESLint Fixes**: Some minor fixes to the linter config to prevent
yelling about minor ES6 things and ensuring we have the correct parser.

Test Plan: new tests

Reviewers: bengotow, juan, drew

Differential Revision: https://phab.nylas.com/D2419

Remove cloudState and N1-Send-Later
2016-01-15 15:16:21 -05:00
Ben Gotow 3a8a38b8bc Merge branch 'master' into unified-inbox
# Conflicts:
#	spec/stores/file-download-store-spec.coffee
2016-01-13 17:20:34 -08:00
Ben Gotow 8cd3176574 build(linux): Ensure that target files are not group writable
Should fix #710. Will move all 0775 => 0755 and 0664 => 0644
2016-01-13 16:09:53 -08:00
Karim Hamidou 4ba827fc48 set the ContentType when uploading packages to S3. 2016-01-13 11:12:39 -08:00
Ben Gotow 728375d9f9 Bump submodule reference 2016-01-11 16:21:05 -08:00
Ben Gotow 9acdb3923f Merge branch 'bengotow/consolidate-plugins' 2016-01-07 14:57:34 -08:00
Ben Gotow 460a715e4d fix(examples): examples => packages, move away from installing them 2016-01-07 14:56:34 -08:00
Evan Morikawa 6db0d8bc46 Add 'default' tasks 2016-01-06 15:55:14 -08:00
Ben Gotow 1ba8f5277f fix(rpm): Treat-deb and-rpm as separate platforms on N1Server 2016-01-05 17:51:02 -08:00
Ben Gotow 41d1c551a5 fix(rpm): Upload RPM builds following naming convention 2016-01-05 17:32:11 -08:00
mbilker 8182f2ef89 fix(grunt): replace shareDir with linuxShareDir to reflect global changes
The `install` task would fail since `linuxShareDir` was undefined for the
template `.desktop` file.
2016-01-04 22:08:20 -05:00
Evan Morikawa 3cd42303ae fix(build): debian packages use different share dir 2016-01-04 16:39:43 -08:00
Evan Morikawa 9530a84877 feat(build): new rpm builds
Summary: Now builds RPM on Travis

Test Plan: manual

Reviewers: juan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2391
2016-01-04 09:56:14 -08:00
Evan Morikawa 616821d09e fix(date): copyright year auto-updates 2016-01-04 09:41:28 -08:00
Juan Tejada 6315bc9d80 fix(extension-adapter): Update adapter to support all versions of extension api we've used
Summary:
- Rewrites composer extension adpater to support all versions of the
  ComposerExtension API we've ever declared. This will allow old plugins (or
  plugins that haven't been reinstalled after update) to keep functioning
  without breaking N1
- Adds specs

Test Plan: - Unit tests

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2399
2015-12-30 15:11:37 -05:00
Dave Perdue 848fb0d688 Fix broken GNOME dock icon
This addresses an issue mentioned in Issue #465 regarding a missing icon.
2015-12-16 12:14:26 -08:00
Dave Perdue 2fc66a42fa Remove redundant path in .desktop for Linux
The install-task has two instructions that add an extra "resources" to the iconName directory and thus the icon doesn't work. The resulting nylus.desktop has an invalid path for the icon.
2015-12-16 11:59:01 -08:00
Ben Gotow 159bb51a10 fix(locales): Copy lproj files to ensure navigator.language works
See https://github.com/atom/electron/issues/2484
2015-12-15 11:34:56 -08:00
Evan Morikawa 267a339250 fix(bootstrap): split commands 2015-12-14 15:22:47 -08:00
Juan Tejada 5a8ca1ef51 add(integration-test): Adds test for onboarding flow with Exchange
Summary:
- Make sure user can log in using exchange
- Adds some test helpers for the test
- Updates eslint.json and cleans up lint errors

Test Plan: - Integration Tests

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2346
2015-12-14 15:14:58 -08:00
Ben Gotow 8ea8df8efc fix(ci): stable instead of release/* branches 2015-12-11 17:13:42 -08:00
Ben Gotow 0f67438c9f fix(ci): Publish appveyor release branch builds 2015-12-11 15:11:13 -08:00
Ben Gotow 922a9e80ec fix(ci): Publish builds on release branches 2015-12-11 14:44:53 -08:00
Ben Gotow 0e4e736607 Merge pull request #628 from mbilker/task-helper-undefined-process-env
Replace function accessor with property accessor in Grunt's task-helper script
2015-12-09 16:02:09 -08:00
Evan Morikawa a2c8145a75 bump(internal): update submodule reference 2015-12-09 18:14:01 -05:00
Evan Morikawa aef0c8a681 fix(spellcheck): check for existing languages and add tests 2015-12-09 18:10:55 -05:00
Ben Gotow 8ecf3bba3f fix(auth): Log first account creation 2015-12-08 17:05:59 -08:00
mbilker 23a2de603c fix(tests): replace () with [] for properties of process.env
This bug appeared during a Travis test run, and only appeared on
the Linux hosts running the tests. The function appears to treat
the `process.env` as a set of functions, not properties. This
commit correctly interprets them as properties.
2015-12-08 18:06:41 -05:00
Evan Morikawa d95cb45147 feat(ci): add Travis and AppVeyor ci support 2015-12-07 12:48:26 -05:00
Juan Tejada 07f81f81a6 feat(components): Add EditableList component to component-kit
Summary:
- Generic list component wich supports adding, editing and removing
string-like items or components
- Needs some css love

Test Plan: - Unit tests.

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2322
2015-12-07 08:15:40 -08:00
Evan Morikawa 1fb58d5c52 feat(build): add nylas resources 2015-12-02 15:12:56 -08:00
Evan Morikawa 2f1a6c3dd8 feat(build): add nylas build resources 2015-12-02 13:59:54 -08:00
Evan Morikawa 73e7c1c52e feat(tests): add integration tests
comment

Adding test harness

Using key strokes in main window test

Tests work now

Clean up argument variables

Rename list manager and get rid of old spec-helper methods

Extract out time overrides from spec-helper

Spectron test for contenteditable

fix spec exit codes and boot mode

fix(spec): cleanup N1.sh and make specs fail with exit code 1

Revert tests and get it working in window

Move to spec_integration and add window load tester

Specs pass. Console logs still in

Remove console logs

Extract N1 Launcher ready method

Make integrated unit test runner

feat(tests): adding integration tests

Summary:
The /spectron folder got moved to /spec_integration

There are now unit tests (the old ones) run via the renamed
`script/grunt run-unit-tests`

There are now integration tests run via the command `script/grunt
run-integration-tests`.

There are two types of integration tests:
1. Tests that operate on the whole app via Selenium/Chromedriver. These
tests have access to Spectron APIs but do NOT have access to any JS object
running inside the application. See the `app-boot-spec.es6` for an example
of these tests. This is tricky because we want to test the Main window,
but Spectron may latch onto any other of our loading windows. Code in
`integration-helper` give us an API that finds and loads the main window
so we can test it

2. Tests that run in the unit test suite that need Spectron to perform
integration-like behavior. These are the contentedtiable specs. The
Spectron server is accessed from the app and can be used to trigger
actions on the running app, from the app. These tests use the
windowed-test runner so Spectron can identify whether the tests have
completed, passed, or failed. Unfortunately Spectron can't access the logs
, nor the exit code of the test script thereby forcing us to parse the
HTML DOM. (Note this is still a WIP)

I also revamped the `N1.sh` file when getting the launch arguments to work
properly. It's much cleaner. We didn't need most of the data.

Test Plan: new tests

Reviewers: juan, bengotow

Differential Revision: https://phab.nylas.com/D2289

Fix composer specs

Tests can properly detect when Spectron is in the environment

Report plain text output in specs

fixing contenteditable specs

Testing slow keymaps on contenteditable specs

Move to DOm mutation

Spell as `subtree` not `subTree`
2015-12-02 13:41:14 -08:00
Ben Gotow 02633ffd57 fix(build): Temporarily disable tests on linux CI. See details
The linux CI server @ Nylas is running debian wheezy, which is too old to run N1 / Electron 0.35+. We need to switch to making the builds with Travis or https://packagecloud.io/.
2015-11-30 15:04:28 -08:00
Ben Gotow 9899de30a2 fix(specs): Remove promise usage, process.env as fn to fix node 0.10 2015-11-30 12:39:17 -08:00
mbilker e3460a7a9b fix(redhat-spec): copy 512x512 icon to /usr/local/share/nylas/resources/app/nylas.png
The icon build/resources/nylas.png is exactly the same as build/resources/linux/icons/512.png
Not confident that the spec script is run from base N1 directory to use the nylas.png in the spec file
2015-11-27 16:20:04 -05:00
mbilker e32d52ff3d fix(grunt): update location of rpm icon name 2015-11-27 15:18:46 -05:00
mbilker c46a38362f fix(fedora-spec): copy nylas icons into hicolor folder 2015-11-27 14:41:53 -05:00
Evan Morikawa 2dea234de0 fix(task): spec task uses Promise 2015-11-26 13:03:44 -08:00
Ben Gotow 72a840e1f0 rm(spectron): Don't run during CI builds, it's timeout-based and fails randomly 2015-11-25 15:06:34 -08:00
Ben Gotow 1889bfac9d Merge pull request #396 from luixal/patch-2
Allows package to be installed in ElementaryOS
2015-11-25 14:38:17 -08:00