Commit Graph

63 Commits

Author SHA1 Message Date
Nick Martin
11d43de256 disable test that breaks other tests 2014-10-11 20:44:02 -07:00
Emily Stark
f102432892 Add some selftest.markStack's and selftest.fail's 2014-10-10 23:39:31 -07:00
David Glasser
1df375d3a2 Fix test-package-server tag
... and also make some fixes to the 'update package server data' test,
though it's possible that only the other change is strictly necessary
2014-10-08 17:21:44 -07:00
ekatek
6c8b0832d7 do not use clone since the catalog is backed by a real db 2014-10-08 16:04:13 -07:00
Emily Stark
1e3e65fbf5 Use single quotes in 'packages with organizations' selftest 2014-10-08 15:26:36 -07:00
David Glasser
3faf1aa21e make test more convincing 2014-10-07 18:26:21 -07:00
ekatek
e0414f2ed5 allow user to mark packages as debugOnly and not have them bundle in production mode
(still outstanding: changes to package publication workflow)

A package marked debugOnly in the package source is not to be bundled in production.
Moreover, if a package/app depends on a debugOnly package, that entire tree should
not be bundled. (But we should take it into account when figuring out versions!)

Does the following:

- In the catalog, we have a function that takes in a set of versions and a set of original
constraints and traverses it, recursively, to build a subset of versions that we *should*
bundle, and the corresponding subset of versions that we shouldn't (because they are either
debugOnly themselves or pulled in by debugOnly packages). (We do this in the catalog because
it is an addon onto the results of the constraint solver, tied deeply into our representation
of data)

- In the packageLoader, we keep track packages & versions that we should bundle, and also,
packages that we should exclude. We do this in the package-loader because, essentially, that's the
object that we use to keep the results of the constraint-solver, and we already propagate it to all
functions that care about it. (Possibly we should subsequently rename it later).

- In the compiler, when we figure out buildTimeDependencies, we ask if we need to bundle debug
builds. If not, we filter them out (see above). Also, when we actually build together unibuilds,
we don't touch the ones that the packageloader tells us to exclude (which ensures that they don't make
it into the final product).

- In the project, we keep track of whether this project is building in debug mode. That's because the project
is where we keep the state of our curent project that we are building, and if we are ever in the state of
building multiple things, then that's the code that we would need to touch (see also that we make a similar
assumption when solving constraints).

- Adds the option to keepthe project debug-build-free and calls it in commands when approporiate.
2014-10-07 15:55:50 -07:00
ekatek
c67de0830a merging from sqllite 2014-09-30 16:29:41 -07:00
ekatek
69df87ce7d mark tests that publish as checkout only
When we publish things to the test packaging server, we use the versionsFrom
argument that is very difficult to set up right to actually work. Most of the time
we don't really set that up and just agree that those tests should fail. As such, I
am going to mark most of those tests as checkout-only for now (we still usually check
that we can publish manually anyway as part of poking at the release in QA, and there is
not a lot of reason that I can think of why publishing from release would be different than
pubishing from checkout. So, marking these as checkout-only until we can get a better
testing infrastructure for this in place.
2014-09-30 12:22:09 -07:00
ekatek
f4563457e8 fix the update server package data unit test
Rewrote parts of the update server package data unit test to compare a pre-sync and a
post-sync catalog, rather than the output of package client's attempts to contact the server.
This is because in the new world, there is no accurate output, and instead, the function
modifies the catalog in place. Additionally, removed the old function that read from
data.json, since it was not used anymore, and cleaned up some comments and return values in
package-client. We no longer claim to return the contents of data.json, instead we return
an object that signals if we should reset the entire catalog, and/or if our connection to the
server flat-out failed. I am not sure that this is the best abstraction for this piece of code
(why does package-client modify the catalog, but not reset it, for example? Since resetting
has consequences, in the ideal world, the package-client would only have the logic to get data
from the server and it would be up to the catalog to figure out how to insert it into sql lite,
I think, maybe. Regardless, now is not the time to do that refactoring.)

The test is a little odd in the following ways. First, comparing every record ever published is
something that is already significantly harder than it used to be, and will get only harder from
there. (However, the test claims to check that no data has been erased, so we need to check it).
We check the vague existence of most records, on the theory that it is unlikely that
we only got a portion of the record in, rather than the entire thing. Second, it doesn't check the
actual contents on disk, because I wasn't sure about writing another interface to sqllite this
late in the game. There are some ways to get around this -- we could be sneaky and submit a non-blank
syncToken in some way (faking a previous sync), so we only get the packages touched since (time X).
Usually, that might violate some internal consistency, but we only care about the contents at this stage.
Second, we should probably write some method on the catalogs to compare themselves instead of making
and querying a copy.For now, though, I think that this is sufficiently expedient.

Also, the test publishes 5 packages. That's a lot of packages, so I marked it as slow.
2014-09-29 22:16:32 -07:00
ekatek
8ce15905c2 to check syncing, we now need to create a new 'remoteCatalog' and sync into it 2014-09-29 22:16:31 -07:00
Pascal Rapicault
32a0178e88 merge devel 2014-09-22 22:59:15 -04:00
ekatek
d8377487dc support multiple major versions in meteor 0.9.3 and above. A little hacky in the tool around keeping old interfaces, but it works 2014-09-18 00:12:30 -07:00
Pascal Rapicault
5173bfe881 change test to accomodate for different ordering 2014-09-17 20:41:24 -04:00
Emily Stark
ccfee68145 Merge branch 'master' into devel
Conflicts:
	docs/client/api.html
	docs/client/data.js
	docs/client/names.json
	meteor
	packages/autoupdate/package.js
	packages/base64/.gitignore
	packages/constraint-solver/package.js
	packages/device-orientation/.gitignore
	packages/less/package.js
	packages/meteor-tool/package.js
	packages/meteor/package.js
	packages/package-version-parser/package.js
	packages/webapp/webapp_server.js
	scripts/admin/meteor-release-experimental.json
	tools/commands.js
	tools/help.txt
	tools/package-version-parser.js
	tools/run-all.js
	tools/tests/apps/build-errors/packages/with-colon-plugin/.gitignore
2014-09-15 14:48:57 -07:00
Emily Stark
e192a9da67 standard-app-packages -> meteor-platform in self-test 2014-09-09 18:26:30 -07:00
ekatek
debb13fdb6 refactorred the update function to be legible and have fewer bugs 2014-09-05 18:21:24 -07:00
David Greenspan
0b1d744731 Merge branch 'reactive-dict' into devel
Conflicts:
	examples/todos/.meteor/versions
2014-09-03 15:20:09 -07:00
Slava Kim
a6c4ed6e6e Merge branch 'release-0.9.1' into release-0.9.2
Conflicts:
	packages/autoupdate/package.js
	packages/meteor-tool/package.js
	packages/meteor/package.js
	scripts/admin/meteor-release-experimental.json
2014-09-02 13:49:21 -07:00
Sashko Stubailo
84f1fcace1 Fix docs and self-test 2014-08-29 11:52:33 -07:00
Matthew Arbesfeld
fca5c382d5 Merge branch 'release-0.9.1' into cordova-hcp
Conflicts:
	docs/client/api.html
	docs/client/api.js
	meteor
	packages/autoupdate/autoupdate_server.js
	packages/autoupdate/package.js
	packages/constraint-solver/package.js
	packages/less/package.js
	packages/meteor-tool/package.js
	packages/meteor/package.js
	packages/minimongo/package.js
	packages/mongo-livedata/package.js
	packages/oauth1/package.js
	packages/package-version-parser/package.js
	packages/spiderable/package.js
	packages/standard-app-packages/package.js
	packages/templating/package.js
	packages/test-in-console/package.js
	packages/webapp/package.js
	scripts/admin/meteor-release-experimental.json
	scripts/generate-dev-bundle.sh
	tools/uniload.js
2014-08-28 21:13:59 -07:00
Emily Stark
1b9f57322b Add packages organizations selftest 2014-08-27 15:56:08 -07:00
Emily Stark
fc1b3e596e Don't require test package server to have 'standard-app-packages' 2014-08-27 15:56:07 -07:00
Matthew Arbesfeld
75427d70ce Merge branch 'devel' into cordova-hcp
Conflicts:
	docs/client/docs.js
	examples/leaderboard/.meteor/versions
	meteor
	packages/backbone/package.js
	packages/constraint-solver/package.js
	packages/meetup/package.js
	packages/meteor-tool/package.js
	packages/showdown/package.js
	packages/stylus/package.js
	scripts/admin/meteor-release-experimental.json
	tools/commands-packages.js
	tools/commands.js
	tools/project.js
	tools/tests/old/app-with-private/.meteor/versions
	tools/tests/old/app-with-public/.meteor/versions
	tools/tests/old/empty-app/.meteor/versions
2014-08-27 13:38:57 -07:00
Emily Stark
f89e633553 Add 'net' tag to "talk to package server" test 2014-08-26 18:19:24 -07:00
Emily Stark
38d6525cea Do login prompt when talking to package server with expired credential 2014-08-26 17:04:42 -07:00
David Glasser
175fd7c3b4 minor test cleanup 2014-08-25 09:42:21 -07:00
David Glasser
08b2625082 METEOR-CORE -> METEOR 2014-08-24 18:46:37 -07:00
David Glasser
a4c5009cea fix 'sync local catalog' test
there was an unnecessarily strong ordering assumption
2014-08-21 19:43:54 -07:00
Matthew Arbesfeld
9c7d279dcf Some test fixes 2014-08-20 23:06:59 -07:00
Matthew Arbesfeld
b78bca197e Fix command line test 2014-08-20 21:19:50 -07:00
Matthew Arbesfeld
df38c100a9 Merge branch 'release-0.9.0' into cordova-hcp
Conflicts:
	tools/commands-packages.js
	tools/utils.js
2014-08-20 20:57:24 -07:00
Matthew Arbesfeld
922af65765 Merge branch 'devel' into cordova-hcp
Conflicts:
	meteor
	scripts/generate-dev-bundle.sh
	tools/bundler.js
	tools/unipackage.js
2014-08-20 19:48:26 -07:00
David Glasser
6f1c74465b adjust which tests are from checkout 2014-08-19 19:34:26 -07:00
ekatek
ff8498dd1b mark tests from checkout if they use the test server due to release duplication issues 2014-08-19 17:07:53 -07:00
ekatek
52e3eafa5c tests and minor fixes for --name 2014-08-19 12:32:16 -07:00
Matthew Arbesfeld
e9b9132a04 Merge branch 'devel' into cordova-hcp
Conflicts:
	meteor
	tools/catalog.js
	tools/commands-packages.js
	tools/commands.js
2014-08-13 15:07:42 -07:00
David Glasser
3656356f22 test for breaking/fixing package.js 2014-08-11 17:59:15 -04:00
David Glasser
64d939acb2 Add a lot more buildmessage captures
Many of these (mostly in top level commands in commands-packages.js) are
not super well thought out: they use a new "doOrDie" helper to run some
function in a capture and exit if there are any messages.  We really
need to get a little more thoughtful about the big picture of error
handling (combining "build" errors, network errors, catalog errors,
etc). But this at least allows the addition of more buildmessage
assertions.

At the very least, this ensures that if you edit a package.js in a local
package while "meteor run" is running, that instead of crashing the tool
it properly shows the buildmessage and lets you fix the issue.
2014-08-11 17:06:28 -04:00
David Glasser
52230a8d79 fix 'update server package data unit test'
various things were not talking to the test server / storage file
2014-08-06 19:56:48 -07:00
Matthew Arbesfeld
9f2ee36e60 Merge branch 'packaging' into cordova-hcp
Conflicts:
	packages/constraint-solver/constraint-solver-tests.js
	packages/constraint-solver/constraint-solver.js
	packages/less/plugin/compile-less.js
	packages/meteor/plugin/basic-file-types.js
	packages/star-translate/translator.js
	packages/stylus/plugin/compile-stylus.js
	packages/templating/plugin/compile-templates.js
	packages/webapp/webapp_server.js
	tools/bundler.js
	tools/commands.js
	tools/compiler.js
	tools/package-source.js
	tools/run-app.js
	tools/selftest.js
	tools/tests/old/test-bundler-assets.js
	tools/tests/old/test-bundler-options.js
	tools/unipackage.js
2014-08-06 13:43:56 -07:00
David Glasser
332215ae7d wipe all packages (from this server) on resetData
note that we should NOT wipe the symlinked tool if we're running from a
release, but we haven't done that yet
2014-08-05 17:59:38 -07:00
David Glasser
0422dfb5c6 fix updateServerPackageData test 2014-08-05 15:48:27 -07:00
David Glasser
cd57ac3535 isolate different servers' packages
also, in self-test, only set $METEOR_PACKAGE_SERVER_URL for the specific
runs that actually want the test server (using a tag) rather than kinda
always by accident
2014-07-28 20:45:08 -07:00
ekatek
c622fb4072 label online tests as online 2014-07-25 14:40:43 -07:00
Matthew Arbesfeld
960f8907d3 Merge branch 'packaging' into cordova-hcp
Conflicts:
	packages/constraint-solver/constraint-solver.js
	packages/webapp/webapp_server.js
	tools/tests/package-tests.js
2014-07-25 13:52:34 -07:00
Avital Oliver
a8e372221d Correct comment 2014-07-24 23:35:01 -07:00
ekatek
af8c532411 Fix add-package test with new output. 2014-07-24 18:35:05 -07:00
David Glasser
4428f2b06d sync tests passes 2014-07-24 17:12:14 -07:00
David Glasser
a548efe175 ignore unknown packages in .meteor/versions
Hopefully this isn't ignoring real error cases. The whole
previousSolution data-rewriting hack probably needs to be fixed
anyway. But this seems to work?
2014-07-24 15:26:55 -07:00